On Wed, Dec 14, 2016 at 11:58:10AM +0000, Remi Chaintron wrote: > # HG changeset patch > # User Remi Chaintron <r...@fb.com> > # Date 1481639041 0 > # Tue Dec 13 14:24:01 2016 +0000 > # Branch stable > # Node ID 8120778471f01b41d01f8d13b4176b32d2b8482c > # Parent 217f7db4dae3309bec78e27c85cc90e924b109be > changegroup: enable version 03 on 'lfs' requirement
This also needs to disable 01 and 02 if it spots lfs (or treemanifests for that matter). > > Version 03 is required by the `lfs` extension in order to send flags for > revlog objects over the wire. > > diff --git a/mercurial/changegroup.py b/mercurial/changegroup.py > --- a/mercurial/changegroup.py > +++ b/mercurial/changegroup.py > @@ -879,14 +879,16 @@ > # Changegroup versions that can be applied to the repo > def supportedincomingversions(repo): > versions = allsupportedversions(repo.ui) > - if 'treemanifest' in repo.requirements: > + if ('treemanifest' in repo.requirements or > + 'lfs' in repo.requirements): > versions.add('03') > return versions > > # Changegroup versions that can be created from the repo > def supportedoutgoingversions(repo): > versions = allsupportedversions(repo.ui) > - if 'treemanifest' in repo.requirements: > + if ('treemanifest' in repo.requirements or > + 'lfs' in repo.requirements): > # Versions 01 and 02 support only flat manifests and it's just too > # expensive to convert between the flat manifest and tree manifest on > # the fly. Since tree manifests are hashed differently, all of > history > diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py > --- a/mercurial/localrepo.py > +++ b/mercurial/localrepo.py > @@ -239,7 +239,7 @@ > class localrepository(object): > > supportedformats = set(('revlogv1', 'generaldelta', 'treemanifest', > - 'manifestv2')) > + 'manifestv2', 'lfs')) > _basesupported = supportedformats | set(('store', 'fncache', 'shared', > 'dotencode')) > openerreqs = set(('revlogv1', 'generaldelta', 'treemanifest', > 'manifestv2')) > _______________________________________________ > Mercurial-devel mailing list > Mercurial-devel@mercurial-scm.org > https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel