changeset 4848:5e365008360f

python 2.3 does not have sorted
author Brendan Cully <brendan@kublai.com>
date Fri, 06 Jul 2007 10:29:09 -0700
parents 845e0071b704
children 035489f60842 7031d9e2fa45
files hgext/convert/subversion.py mercurial/changelog.py
diffstat 2 files changed, 6 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/convert/subversion.py	Fri Jul 06 10:22:22 2007 -0700
+++ b/hgext/convert/subversion.py	Fri Jul 06 10:29:09 2007 -0700
@@ -286,7 +286,9 @@
             except IndexError:
                 branch = None
 
-            for path in sorted(orig_paths):
+            paths = orig_paths.keys()
+            paths.sort()
+            for path in paths:
                 # self.ui.write("path %s\n" % path)
                 if path == self.module: # Follow branching back in history
                     ent = orig_paths[path]
--- a/mercurial/changelog.py	Fri Jul 06 10:22:22 2007 -0700
+++ b/mercurial/changelog.py	Fri Jul 06 10:29:09 2007 -0700
@@ -132,7 +132,9 @@
 
     def encode_extra(self, d):
         # keys must be sorted to produce a deterministic changelog entry
-        items = [_string_escape('%s:%s' % (k, d[k])) for k in sorted(d)]
+        keys = d.keys()
+        keys.sort()
+        items = [_string_escape('%s:%s' % (k, d[k])) for k in keys]
         return "\0".join(items)
 
     def extract(self, text):