obsolete: move old format stuff at the end
authorPierre-Yves David <pierre-yves.david@logilab.fr>
Tue, 07 Aug 2012 14:00:39 +0200
changeset 430 07db1d511faf
parent 429 079b231b8ea4
child 431 bd05022c7856
obsolete: move old format stuff at the end
hgext/obsolete.py
--- a/hgext/obsolete.py	Tue Aug 07 14:08:31 2012 +0200
+++ b/hgext/obsolete.py	Tue Aug 07 14:00:39 2012 +0200
@@ -929,12 +929,20 @@
                     ex.hint = hint
                 raise
             return result
+    repo.__class__ = obsoletingrepo
 
 
-    repo.__class__ = obsoletingrepo
+#####################################################################
+### Older format management                                       ###
+#####################################################################
+
+# Code related to detection and management of older legacy format never
+# handled by core
 
 @eh.reposetup
 def _checkoldobsolete(ui, repo):
+    """Detect that a repo still carry some old obsolete format
+    """
     if not repo.local():
         return
     for arg in sys.argv:
@@ -948,9 +956,6 @@
             raise util.Abort('old format of obsolete marker detected!\n'
                              'run `hg debugconvertobsolete` once.')
 
-### serialisation
-#############################
-
 def _obsdeserialise(flike):
     """read a file like object serialised with _obsserialise