Show More
@@ -36,7 +36,8 b' def findcommonincoming(repo, remote, hea' | |||
|
36 | 36 | base = set() |
|
37 | 37 | |
|
38 | 38 | if not heads: |
|
39 | heads = remote.heads() | |
|
39 | with remote.commandexecutor() as e: | |
|
40 | heads = e.callcommand('heads', {}).result() | |
|
40 | 41 | |
|
41 | 42 | if repo.changelog.tip() == nullid: |
|
42 | 43 | base.add(nullid) |
@@ -65,7 +66,10 b' def findcommonincoming(repo, remote, hea' | |||
|
65 | 66 | # a 'branch' here is a linear segment of history, with four parts: |
|
66 | 67 | # head, root, first parent, second parent |
|
67 | 68 | # (a branch always has two parents (or none) by definition) |
|
68 | unknown = collections.deque(remote.branches(unknown)) | |
|
69 | with remote.commandexecutor() as e: | |
|
70 | branches = e.callcommand('branches', {'nodes': unknown}).result() | |
|
71 | ||
|
72 | unknown = collections.deque(branches) | |
|
69 | 73 | while unknown: |
|
70 | 74 | r = [] |
|
71 | 75 | while unknown: |
@@ -107,7 +111,12 b' def findcommonincoming(repo, remote, hea' | |||
|
107 | 111 | repo.ui.debug("request %d: %s\n" % |
|
108 | 112 | (reqcnt, " ".join(map(short, r)))) |
|
109 | 113 | for p in xrange(0, len(r), 10): |
|
110 | for b in remote.branches(r[p:p + 10]): | |
|
114 | with remote.commandexecutor() as e: | |
|
115 | branches = e.callcommand('branches', { | |
|
116 | 'nodes': r[p:p + 10], | |
|
117 | }).result() | |
|
118 | ||
|
119 | for b in branches: | |
|
111 | 120 | repo.ui.debug("received %s:%s\n" % |
|
112 | 121 | (short(b[0]), short(b[1]))) |
|
113 | 122 | unknown.append(b) |
@@ -117,7 +126,11 b' def findcommonincoming(repo, remote, hea' | |||
|
117 | 126 | newsearch = [] |
|
118 | 127 | reqcnt += 1 |
|
119 | 128 | repo.ui.progress(_('searching'), reqcnt, unit=_('queries')) |
|
120 | for n, l in zip(search, remote.between(search)): | |
|
129 | ||
|
130 | with remote.commandexecutor() as e: | |
|
131 | between = e.callcommand('between', {'pairs': search}).result() | |
|
132 | ||
|
133 | for n, l in zip(search, between): | |
|
121 | 134 | l.append(n[1]) |
|
122 | 135 | p = n[0] |
|
123 | 136 | f = 1 |
General Comments 0
You need to be logged in to leave comments.
Login now