diff -r b5d7e7d5c573 -r 91f0677dc920 mercurial/changegroup.py --- a/mercurial/changegroup.py Thu Sep 14 11:16:47 2017 -0700 +++ b/mercurial/changegroup.py Thu Sep 14 11:16:57 2017 -0700 @@ -872,6 +872,11 @@ versions.discard('02') return versions +def localversion(repo): + # Finds the best version to use for bundles that are meant to be used + # locally, such as those from strip and shelve, and temporary bundles. + return max(supportedoutgoingversions(repo)) + def safeversion(repo): # Finds the smallest version that it's safe to assume clients of the repo # will support. For example, all hg versions that support generaldelta also