diff options
author | Benedikt Morbach <bmorbach@redhat.com> | 2014-08-11 14:55:51 +0200 |
---|---|---|
committer | Benedikt Morbach <bmorbach@redhat.com> | 2014-08-11 14:55:51 +0200 |
commit | 2ad1b48388b6000c051faee76e5441604352588e (patch) | |
tree | 5134e408eac4b8f4e2a4fa6518f66ddd739ad368 | |
parent | 0ea795ea56787d22e12aa8db01c5424f529cf2f7 (diff) | |
download | wheel-2ad1b48388b6000c051faee76e5441604352588e.tar.gz |
make order of lines in METADATA deterministic
-rw-r--r-- | wheel/metadata.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/wheel/metadata.py b/wheel/metadata.py index 40ce296..ca9643f 100644 --- a/wheel/metadata.py +++ b/wheel/metadata.py @@ -238,7 +238,7 @@ 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 pkg_resources.split_sections(requires): + for extra, reqs in sorted(pkg_resources.split_sections(requires)): condition = '' if extra and ':' in extra: # setuptools extra:condition syntax extra, condition = extra.split(':', 1) @@ -249,7 +249,7 @@ def pkginfo_to_metadata(egg_info_path, pkginfo_path): condition += 'extra == %s' % repr(extra) if condition: condition = '; ' + condition - for new_req in convert_requirements(reqs): + for new_req in sorted(convert_requirements(reqs)): pkg_info['Requires-Dist'] = new_req + condition description = pkg_info['Description'] |