def relpath(path, start):
    """Get relative path to start.

    Note: Modeled after python2.6 :meth:`os.path.relpath`.
    """
    path_items = path_list(path)
    start_items = path_list(start)

    # Find common parts of path.
    common = []
    for pth, stt in zip(path_items, start_items):
        if pth != stt:
            break
        common.append(pth)

    # Shared parts index in both lists.
    common_ind = len(common)
    parent_num = common_ind - len(start_items)

    # Start with parent traversal and add relative parts.
    rel_items = [PARENT] * parent_num + path_items[common_ind:]
    return path_join(*rel_items)  # pylint: disable=W0142
dataset/ETHPy150Open ryan-roemer/django-cloud-browser/cloud_browser/common.py/relpath/swapped operands of `-`