##// END OF EJS Templates
merge: catch unexpected responses...
mpm@selenic.com -
r217:e6d6497a default
parent child Browse files
Show More
@@ -933,14 +933,22 b' class remoterepository:'
933 def branches(self, nodes):
933 def branches(self, nodes):
934 n = " ".join(map(hex, nodes))
934 n = " ".join(map(hex, nodes))
935 d = self.do_cmd("branches", nodes=n).read()
935 d = self.do_cmd("branches", nodes=n).read()
936 br = [ tuple(map(bin, b.split(" "))) for b in d.splitlines() ]
936 try:
937 return br
937 br = [ tuple(map(bin, b.split(" "))) for b in d.splitlines() ]
938 return br
939 except:
940 self.ui.warn("unexpected response:\n" + d[:400] + "\n...\n")
941 raise
938
942
939 def between(self, pairs):
943 def between(self, pairs):
940 n = "\n".join(["-".join(map(hex, p)) for p in pairs])
944 n = "\n".join(["-".join(map(hex, p)) for p in pairs])
941 d = self.do_cmd("between", pairs=n).read()
945 d = self.do_cmd("between", pairs=n).read()
942 p = [ l and map(bin, l.split(" ")) or [] for l in d.splitlines() ]
946 try:
943 return p
947 p = [ l and map(bin, l.split(" ")) or [] for l in d.splitlines() ]
948 return p
949 except:
950 self.ui.warn("unexpected response:\n" + d[:400] + "\n...\n")
951 raise
944
952
945 def changegroup(self, nodes):
953 def changegroup(self, nodes):
946 n = " ".join(map(hex, nodes))
954 n = " ".join(map(hex, nodes))
General Comments 0
You need to be logged in to leave comments. Login now