obsolete: explicitly pass metadata argument using keyword argument
We are about to add more arguments to this function (date, parents, etc).
Passing metadata as a keyword argument gives us more flexibility when adding
them.
--- a/mercurial/commands.py Fri Aug 15 09:41:30 2014 -0700
+++ b/mercurial/commands.py Thu Aug 14 01:53:07 2014 -0700
@@ -2341,7 +2341,7 @@
try:
try:
repo.obsstore.create(tr, parsenodeid(precursor), succs,
- opts['flags'], metadata)
+ opts['flags'], metadata=metadata)
tr.close()
except ValueError, exc:
raise util.Abort(_('bad obsmarker input: %s') % exc)
--- a/mercurial/obsolete.py Fri Aug 15 09:41:30 2014 -0700
+++ b/mercurial/obsolete.py Thu Aug 14 01:53:07 2014 -0700
@@ -868,7 +868,8 @@
nsucs = tuple(s.node() for s in sucs)
if nprec in nsucs:
raise util.Abort("changeset %s cannot obsolete itself" % prec)
- repo.obsstore.create(tr, nprec, nsucs, flag, localmetadata)
+ repo.obsstore.create(tr, nprec, nsucs, flag,
+ metadata=localmetadata)
repo.filteredrevcache.clear()
tr.close()
finally: