summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Holth <dholth@fastmail.fm>2014-11-12 21:10:08 -0500
committerDaniel Holth <dholth@fastmail.fm>2014-11-12 21:10:08 -0500
commit2c13a19f32a31b6ec72597fdec71f8a697c46865 (patch)
tree2dbf73f5c56f513da832418be5a998a1e689231c
parent6953c419b5cda0a9fcac6041bbcc39937a221d13 (diff)
downloadwheel-2c13a19f32a31b6ec72597fdec71f8a697c46865.tar.gz
fix sorting for deterministic metadata generation for Python 3
-rw-r--r--tox.ini1
-rw-r--r--wheel/metadata.py3
2 files changed, 2 insertions, 2 deletions
diff --git a/tox.ini b/tox.ini
index 18fa2c8..f1e6a10 100644
--- a/tox.ini
+++ b/tox.ini
@@ -11,7 +11,6 @@ commands =
py.test
deps =
jsonschema
- coverage
pytest
pytest-cov
wheel[tool,signatures]
diff --git a/wheel/metadata.py b/wheel/metadata.py
index ca9643f..02c0663 100644
--- a/wheel/metadata.py
+++ b/wheel/metadata.py
@@ -238,7 +238,8 @@ def pkginfo_to_metadata(egg_info_path, pkginfo_path):
requires_path = os.path.join(egg_info_path, 'requires.txt')
if os.path.exists(requires_path):
requires = open(requires_path).read()
- for extra, reqs in sorted(pkg_resources.split_sections(requires)):
+ for extra, reqs in sorted(pkg_resources.split_sections(requires),
+ key=lambda x: x[0] or ''):
condition = ''
if extra and ':' in extra: # setuptools extra:condition syntax
extra, condition = extra.split(':', 1)