diff options
author | Daniel Holth <dholth@fastmail.fm> | 2014-11-12 21:10:08 -0500 |
---|---|---|
committer | Daniel Holth <dholth@fastmail.fm> | 2014-11-12 21:10:08 -0500 |
commit | 2c13a19f32a31b6ec72597fdec71f8a697c46865 (patch) | |
tree | 2dbf73f5c56f513da832418be5a998a1e689231c | |
parent | 6953c419b5cda0a9fcac6041bbcc39937a221d13 (diff) | |
download | wheel-2c13a19f32a31b6ec72597fdec71f8a697c46865.tar.gz |
fix sorting for deterministic metadata generation for Python 3
-rw-r--r-- | tox.ini | 1 | ||||
-rw-r--r-- | wheel/metadata.py | 3 |
2 files changed, 2 insertions, 2 deletions
@@ -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) |