YœRddlZddlZddlZddlZddlmZdedefdZdedefdZ dS) N)WINDOWSpathreturnctjtj|}tjdtj|}|S)zh Convert a path to a file: URL. The path will be made absolute and have quoted path parts. zfile://) osrnormpathabspathurllibparseurljoinrequest pathname2url)rurls j/builddir/build/BUILD/cloudlinux-venv-1.0.10/venv/lib/python3.11/site-packages/pip/_internal/utils/urls.py path_to_urlr sS 7  BGOOD11 2 2D ,  y&.*E*Ed*K*K L LC Jrc|dsJd|dtj|\}}}}}|r|dkrd}ntrd|z}nt d|tj||z}trK|sIt|dkr6|d d kr*|d tj vr|d d dvr |d d}|S)z( Convert a file: URL to a path. zfile:z1You can only turn file: urls into filenames (not ) localhostz\\z8non-local file URIs are not supported on this platform: r/r):z:/N) startswithr r urlsplitr ValueErrorr url2pathnamelenstring ascii_letters)r_netlocrs r url_to_pathr&s0 >>  DDC3CCCDD #L11#66AvtQ   V{**  & Ns N N    > & &v} 5 5D  IINN GsNN Gv+ + + 1I $ $ABBx Kr) rr" urllib.parser urllib.requestcompatrstrrr&rrr,s cc$S$S$$$$$$r