def make_label_from_target(self, target):
        """Create a label from a wiki target.

        A trailing fragment and query string is stripped. Then, leading ./,
        ../ and / elements are stripped, except when this would lead to an
        empty label. Finally, if `split_page_names` is true, the label
        is split accordingly.
        """
        label = target.split('#', 1)[0].split('?', 1)[0]
        if not label:
            return target
        components = label.split('/')
        for i, comp in enumerate(components):
            if ('', '.', '..') not in comp:
                label = '/'.join(components[i:])
                break
        return self.format_page_name(label)
dataset/ETHPy150Open edgewall/trac/trac/wiki/api.py/WikiSystem.make_label_from_target/swapped operands of `not in`