Commit 39f83785 by Mohamed Seleem Committed by Sébastien Eustace

Fix assuming 'default_link' is always a wheel (#729)

parent f84988ab
...@@ -349,11 +349,11 @@ class LegacyRepository(PyPiRepository): ...@@ -349,11 +349,11 @@ class LegacyRepository(PyPiRepository):
default_link = links[0] default_link = links[0]
for link in links: for link in links:
if link.is_wheel: if link.is_wheel:
m = wheel_file_re.match(default_link.filename) m = wheel_file_re.match(link.filename)
python = m.group("pyver") python = m.group("pyver")
platform = m.group("plat") platform = m.group("plat")
if python == "py2.py3" and platform == "any": if python == "py2.py3" and platform == "any":
urls["bdist_wheel"] = default_link.url urls["bdist_wheel"] = link.url
elif link.filename.endswith(".tar.gz"): elif link.filename.endswith(".tar.gz"):
urls["sdist"] = link.url urls["sdist"] = link.url
elif ( elif (
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment