[issue44375] urllib.parse.urlparse is not parsing the url properly

2021-06-10 Thread Gnanesh
Gnanesh added the comment: Hey neethu, For empty schemes, it should have a prefix of "//" in the URL to parse it correctly. Try: > urlparse('//www.cwi.nl:80') ParseResult(scheme='', netloc='www.cwi.nl:80', path='', params='', query='', fragment='') Here's a comment from the docs (https:/

[issue44375] urllib.parse.urlparse is not parsing the url properly

2021-06-10 Thread Neethu
New submission from Neethu : urllib.parse.urlparse is not parsing urls without scheme and with port number properly. from urllib.parse import urlparse print(urlparse("www.cwi.nl:80")) ParseResult(scheme='www.cwi.nl', netloc='', path='80', params='', query='', fragment='') Python version : 3