Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

comments on 'unnamed' requirements

  • Loading branch information...
commit d882827e3f986f15ebdd3e9e82db9bc39890db88 1 parent dc5e825
@qwcode authored
Showing with 3 additions and 1 deletion.
  1. +3 −1 pip/req.py
View
4 pip/req.py
@@ -107,7 +107,7 @@ def from_line(cls, name, comes_from=None):
# Otherwise, assume the name is the req for the non URL/path/archive case.
if link and req is None:
url = link.url_without_fragment
- req = link.egg_fragment
+ req = link.egg_fragment #when fragment is None, this will become an 'unnamed' requirement
# Handle relative file URLs
if link.scheme == 'file' and re.search(r'\.\./', url):
@@ -843,6 +843,7 @@ def add_requirement(self, install_req):
install_req.as_egg = self.as_egg
install_req.use_user_site = self.use_user_site
if not name:
+ #url or path requirement w/o an egg fragment
self.unnamed_requirements.append(install_req)
else:
if self.has_requirement(name):
@@ -1095,6 +1096,7 @@ def prepare_files(self, finder, force_root_egg_info=False, bundle=False):
reqs.append(subreq)
self.add_requirement(subreq)
if not self.has_requirement(req_to_install.name):
+ #'unnamed' requirements will get added here
self.add_requirement(req_to_install)
if self.is_download or req_to_install._temp_build_dir is not None:
self.reqs_to_cleanup.append(req_to_install)
Please sign in to comment.
Something went wrong with that request. Please try again.