Unquote the auth after splitting the url.
TypeError, not AttributeError on 3.3.
Meet @sigmavirus24's demanding stylistic criteria.
Be less defensive in get_auth_from_url.
Don't need to unquote twice.
Merged changes from @lukasa