mirror of https://github.com/pypa/pip
Stop relying on undocumented duck typing by `urlunsplit()`
There are proposals in CPython to enforce correct types (str, bytes, bytearray) in urllib.parse: bpo-19094 and bpo-22234.
This commit is contained in:
parent
ece6a2cdd9
commit
185120d725
|
@ -150,7 +150,7 @@ class Link(KeyBasedCompareMixin):
|
|||
def url_without_fragment(self):
|
||||
# type: () -> str
|
||||
scheme, netloc, path, query, fragment = self._parsed_url
|
||||
return urllib.parse.urlunsplit((scheme, netloc, path, query, None))
|
||||
return urllib.parse.urlunsplit((scheme, netloc, path, query, ''))
|
||||
|
||||
_egg_fragment_re = re.compile(r'[#&]egg=([^&]*)')
|
||||
|
||||
|
|
Loading…
Reference in New Issue