> > While this looks okay I think parsing the URL would be saner for bogus URLs.
>
> In what way do you mean? This is just so that people can put in a truncated
> URL. Are you suggesting I should verify that the URL is actually a legitimate
> structure?
Well instead of using "://" in url and things like that we could parse the url with things like urlparse/urlsplit and then only act on the path component. I'm not advocating for it but it would seem cleaner.
> > While this looks okay I think parsing the URL would be saner for bogus URLs.
>
> In what way do you mean? This is just so that people can put in a truncated
> URL. Are you suggesting I should verify that the URL is actually a legitimate
> structure?
Well instead of using "://" in url and things like that we could parse the url with things like urlparse/urlsplit and then only act on the path component. I'm not advocating for it but it would seem cleaner.