diff hgext3rd/topic/topicmap.py @ 6271:caf302fb8f4d

topic: use branch//namespace/topic format everywhere except exchange We're converting branchmap from using the new "//" format into using the old ":" format as the first step for exchange process. It will make exchange compatible with older clients that had branchmap in the ":" format without topic namespaces. This obviously means that right now topic namespaces don't affect exchange at all.
author Anton Shestakov <av6@dwimlabs.net>
date Fri, 08 Jul 2022 17:54:40 +0400
parents 16f6b18b9ec0
children f4ffe1e67a9b
line wrap: on
line diff
--- a/hgext3rd/topic/topicmap.py	Fri Jul 08 09:50:12 2022 +0200
+++ b/hgext3rd/topic/topicmap.py	Fri Jul 08 17:54:40 2022 +0400
@@ -219,13 +219,10 @@
 
         def branchinfo(r, changelog=None):
             info = oldgetbranchinfo(r)
-            topic = b''
             ctx = unfi[r]
+            branch = info[0]
             if ctx.mutable():
-                topic = ctx.topic()
-            branch = info[0]
-            if topic:
-                branch = b'%s:%s' % (branch, topic)
+                branch = ctx.fqbn()
             return (branch, info[1])
         try:
             unfi.revbranchcache().branchinfo = branchinfo