obsstore: add a `parents` argument to obsstore.create
authorPierre-Yves David <pierre-yves.david@fb.com>
Mon, 18 Aug 2014 16:12:29 -0700
changeset 22255 adb3798dce49
parent 22254 b8a0e8176693
child 22256 3ae6cc6173e3
obsstore: add a `parents` argument to obsstore.create We need a way to pass the information to the function. Some guru told me that what's arguments are made for.
mercurial/obsolete.py
--- a/mercurial/obsolete.py	Mon Aug 18 16:08:44 2014 -0700
+++ b/mercurial/obsolete.py	Mon Aug 18 16:12:29 2014 -0700
@@ -272,8 +272,8 @@
     def __nonzero__(self):
         return bool(self._all)
 
-    def create(self, transaction, prec, succs=(), flag=0, date=None,
-               metadata=None):
+    def create(self, transaction, prec, succs=(), flag=0, parents=None,
+               date=None, metadata=None):
         """obsolete: add a new obsolete marker
 
         * ensuring it is hashable
@@ -302,7 +302,7 @@
         if prec in succs:
             raise ValueError(_('in-marker cycle with %s') % node.hex(prec))
         marker = (str(prec), tuple(succs), int(flag), encodemeta(metadata),
-                  date, None)
+                  date, parents)
         return bool(self.add(transaction, [marker]))
 
     def add(self, transaction, markers):