upper case url reqs not aliased with name.lower() like other forms #724

Merged
merged 2 commits into from Nov 15, 2012

Projects

None yet

2 participants

@qwcode
Contributor
qwcode commented Nov 14, 2012

consider this requirements file

http://pypi.python.org/packages/source/P/Pygments/Pygments-1.4.tar.gz
pygments-style-solarized

and know that:

  1. "Pygments" is the upper case project name in setup.py
  2. pygments-style-solarized depends on "pygments" lower case.

what you end up with in site-packages is metadata for both being installed:

Pygments-1.4-py2.6.egg-info (whats in the req file)
Pygments-1.5-py2.6.egg-info (the latest)

Pygments is not considered the same as "pygments".

this does not happen, when the requirements file is this:

Pygments==1.4 
pygments-style-solarized

I've also seen cases like this with "Django", where Django is installed with a url link, and some other requirement depends on "django"

the diff here is very small, and I added a test, which required some new packages. the fix amounts to closing a loophole in the way 'unnamed' requirements were being added to the requirement set. they were bypassing the method that adds the lower case alias.

@pnasrat pnasrat merged commit 854574f into pypa:develop Nov 15, 2012

1 check passed

default The Travis build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment