bundle2: make source a mandatory argument for bundle2.applybundle() (API)
authorPulkit Goyal <7895pulkit@gmail.com>
Sat, 31 Mar 2018 14:54:12 +0530
changeset 37238 684a6a261f30
parent 37237 f7d3915d5b3a
child 37239 40ee0af04e3a
bundle2: make source a mandatory argument for bundle2.applybundle() (API) Currently all the callers in the core pass the source argument, making it mandatory will help us storing right source value in bundleoperation() class. Differential Revision: https://phab.mercurial-scm.org/D2996
mercurial/bundle2.py
--- a/mercurial/bundle2.py	Sat Mar 31 14:51:34 2018 +0530
+++ b/mercurial/bundle2.py	Sat Mar 31 14:54:12 2018 +0530
@@ -342,7 +342,7 @@
     to be created"""
     raise TransactionUnavailable()
 
-def applybundle(repo, unbundler, tr, source=None, url=None, **kwargs):
+def applybundle(repo, unbundler, tr, source, url=None, **kwargs):
     # transform me into unbundler.apply() as soon as the freeze is lifted
     if isinstance(unbundler, unbundle20):
         tr.hookargs['bundle2'] = '1'