--- a/hgext3rd/topic/discovery.py Wed Mar 16 12:14:20 2016 -0700
+++ b/hgext3rd/topic/discovery.py Tue Mar 15 17:26:57 2016 +0000
@@ -8,7 +8,7 @@
def _headssummary(orig, repo, remote, outgoing):
publishing = ('phases' not in remote.listkeys('namespaces')
or bool(remote.listkeys('phases').get('publishing', False)))
- if publishing:
+ if publishing or not remote.capable('topics'):
return orig(repo, remote, outgoing)
oldgetitem = repo.__getitem__
oldrepo = repo.__class__
@@ -102,5 +102,10 @@
exchange._pushb2ctxcheckheads(pushop, bundler)
return orig(pushop, bundler)
+def wireprotocaps(orig, repo, proto):
+ caps = orig(repo, proto)
+ if repo.peer().capable('topics'):
+ caps.append('topics')
+ return caps