

def path_to_url(path):
    '\n    Convert a path to URI. The path will be made absolute and\n    will not have quoted path parts.\n    (adapted from pip.util)\n    '
    path = os.path.normpath(os.path.abspath(path))
    (drive, path) = os.path.splitdrive(path)
    filepath = path.split(os.path.sep)
    url = '/'.join(filepath)
    if drive:
        return (('file:///' + drive) + url)
    return ('file://' + url)

dataset/ETHPy150Open pypa/pip/tests/lib/__init__.py path_to_url/original