D4863: wireprotov2: always advertise raw repo requirements
indygreg (Gregory Szorc)
phabricator at mercurial-scm.org
Wed Oct 3 18:13:23 UTC 2018
indygreg created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
I'm pretty sure my original thinking behind making it conditional
on stream clone support was that the behavior mirrored wire protocol
version 1.
I don't see a compelling reason for us to not advertise the server's
storage requirements. The proper way to advertise stream clone support
in wireprotov2 would be to not advertise the command(s) required to
perform stream clone or to advertise a separate capability denoting
stream clone support.
Stream clone isn't yet implemented on wireprotov2, so we can cross
this bridge later.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D4863
AFFECTED FILES
mercurial/wireprotov2server.py
CHANGE DETAILS
diff --git a/mercurial/wireprotov2server.py b/mercurial/wireprotov2server.py
--- a/mercurial/wireprotov2server.py
+++ b/mercurial/wireprotov2server.py
@@ -20,7 +20,6 @@
error,
narrowspec,
pycompat,
- streamclone,
util,
wireprotoframing,
wireprototypes,
@@ -522,9 +521,8 @@
'permissions': [entry.permission],
}
- if streamclone.allowservergeneration(repo):
- caps['rawrepoformats'] = sorted(repo.requirements &
- repo.supportedformats)
+ caps['rawrepoformats'] = sorted(repo.requirements &
+ repo.supportedformats)
targets = getadvertisedredirecttargets(repo, proto)
if targets:
To: indygreg, #hg-reviewers
Cc: mercurial-devel
More information about the Mercurial-devel
mailing list