def __lt__(self, other):

        # convenience
        obj = self.obj
        if isinstance(other, Comparable):
            other = other.obj

        # None < everything else
        if other is None:
            return False
        if obj is None:
            return True

        # numbers < everything else (except None)
        if isinstance(obj, numeric_types) \
                and not isinstance(other, numeric_types):
            return True
        if not isinstance(obj, numeric_types) \
                and isinstance(other, numeric_types):
            return False

        # binary < unicode
        if isinstance(obj, text_type) and isinstance(other, binary_type):
            return False
        if isinstance(obj, binary_type) and isinstance(other, text_type):
            return True

        try:
            # attempt native comparison
            return obj < other

        except __HOLE__:
            # fall back to comparing type names
            return _typestr(obj) < _typestr(other)
dataset/ETHPy150Open alimanfoo/petl/petl/comparison.py/Comparable.__lt__