diff --git a/pyproject.toml b/pyproject.toml index d7c96af3..9aec4b99 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,7 +74,6 @@ known_third_party = [ "environ", "hypothesis", "invoke", - "orderedmultidict", "packaging", "parver", "pep517", diff --git a/setup.cfg b/setup.cfg index 865a4c91..242c9ec6 100644 --- a/setup.cfg +++ b/setup.cfg @@ -43,7 +43,6 @@ install_requires = attrs>=19.2 cached_property distlib>=0.2.8 - orderedmultidict packaging>=19.0 pep517>=0.5.0 pip>=22.2 @@ -52,7 +51,7 @@ install_requires = requests setuptools>=40.8 tomlkit>=0.5.3 - vistir>=0.3.1 + vistir==0.6.1 pyparsing<3.0.0 [options.extras_require] diff --git a/src/requirementslib/models/url.py b/src/requirementslib/models/url.py index 7d3980c3..5d8f0661 100644 --- a/src/requirementslib/models/url.py +++ b/src/requirementslib/models/url.py @@ -6,7 +6,6 @@ from urllib.parse import unquote_plus import attr -from orderedmultidict import omdict from pip._internal.models.link import Link from pip._internal.req.constructors import _strip_extras from urllib3.util import parse_url as urllib3_parse @@ -87,8 +86,8 @@ class URI(object): username = attr.ib(default="", type=str) #: Password parsed from `user:password@hostname` password = attr.ib(default="", type=str, repr=False) - #: An orderedmultidict representing query fragments - query_dict = attr.ib(factory=omdict, type=omdict) + #: A dictionary representing query fragments + query_dict = attr.ib(factory=dict, type=dict) #: The name of the specified package in case it is a VCS URI with an egg fragment name = attr.ib(default="", type=str) #: Any extras requested from the requirement @@ -105,7 +104,7 @@ class URI(object): def _parse_query(self): # type: () -> URI query = self.query if self.query is not None else "" - query_dict = omdict() + query_dict = dict() queries = query.split("&") query_items = [] subdirectory = self.subdirectory if self.subdirectory else None @@ -116,7 +115,7 @@ def _parse_query(self): subdirectory = val else: query_items.append((key, val)) - query_dict.load(query_items) + query_dict.update(query_items) return attr.evolve( self, query_dict=query_dict, subdirectory=subdirectory, query=query )