def _resolve_one(<EOL>self,<EOL>requirement_set,  <EOL>req_to_install,  <EOL>ignore_requires_python=False  <EOL>):<EOL>
<EOL>if req_to_install.constraint or req_to_install.prepared:<EOL><INDENT>return []<EOL><DEDENT>req_to_install.prepared = True<EOL>requirement_set.reqs_to_cleanup.append(req_to_install)<EOL>abstract_dist = self._get_abstract_dist_for(req_to_install)<EOL>dist = abstract_dist.dist()<EOL>try:<EOL><INDENT>check_dist_requires_python(dist)<EOL><DEDENT>except UnsupportedPythonVersion as err:<EOL><INDENT>if self.ignore_requires_python or ignore_requires_python or self.ignore_compatibility:<EOL><INDENT>logger.warning(err.args[<NUM_LIT:0>])<EOL><DEDENT>else:<EOL><INDENT>raise<EOL><DEDENT><DEDENT>try:<EOL><INDENT>self.requires_python = check_dist_requires_python(dist, absorb=False)<EOL><DEDENT>except TypeError:<EOL><INDENT>self.requires_python = None<EOL><DEDENT>more_reqs = []  <EOL>def add_req(subreq, extras_requested):<EOL><INDENT>sub_install_req = install_req_from_req_string(<EOL>str(subreq),<EOL>req_to_install,<EOL>isolated=self.isolated,<EOL>wheel_cache=self.wheel_cache,<EOL>use_pep517=self.use_pep517<EOL>)<EOL>parent_req_name = req_to_install.name<EOL>to_scan_again, add_to_parent = requirement_set.add_requirement(<EOL>sub_install_req,<EOL>parent_req_name=parent_req_name,<EOL>extras_requested=extras_requested,<EOL>)<EOL>if parent_req_name and add_to_parent:<EOL><INDENT>self._discovered_dependencies[parent_req_name].append(<EOL>add_to_parent<EOL>)<EOL><DEDENT>more_reqs.extend(to_scan_again)<EOL><DEDENT>with indent_log():<EOL><INDENT>if not requirement_set.has_requirement(req_to_install.name):<EOL><INDENT>available_requested = sorted(<EOL>set(dist.extras) & set(req_to_install.extras)<EOL>)<EOL>req_to_install.is_direct = True<EOL>requirement_set.add_requirement(<EOL>req_to_install, parent_req_name=None,<EOL>extras_requested=available_requested,<EOL>)<EOL><DEDENT>if not self.ignore_dependencies:<EOL><INDENT>if req_to_install.extras:<EOL><INDENT>logger.debug(<EOL>"<STR_LIT>",<EOL>'<STR_LIT:U+002C>'.join(req_to_install.extras),<EOL>)<EOL><DEDENT>missing_requested = sorted(<EOL>set(req_to_install.extras) - set(dist.extras)<EOL>)<EOL>for missing in missing_requested:<EOL><INDENT>logger.warning(<EOL>'<STR_LIT>',<EOL>dist, missing<EOL>)<EOL><DEDENT>available_requested = sorted(<EOL>set(dist.extras) & set(req_to_install.extras)<EOL>)<EOL>for subreq in dist.requires(available_requested):<EOL><INDENT>add_req(subreq, extras_requested=available_requested)<EOL><DEDENT>for available in available_requested:<EOL><INDENT>if hasattr(dist, '<STR_LIT>'):<EOL><INDENT>for req in dist._DistInfoDistribution__dep_map[available]:<EOL><INDENT>req = InstallRequirement(<EOL>req,<EOL>req_to_install,<EOL>isolated=self.isolated,<EOL>wheel_cache=self.wheel_cache,<EOL>use_pep517=None<EOL>)<EOL>more_reqs.append(req)<EOL><DEDENT><DEDENT><DEDENT><DEDENT>if not req_to_install.editable and not req_to_install.satisfied_by:<EOL><INDENT>requirement_set.successfully_downloaded.append(req_to_install)<EOL><DEDENT><DEDENT>return more_reqs<EOL>
Prepare a single requirements file.

        :return: A list of additional InstallRequirements to also install.