Show More
@@ -1183,7 +1183,7 b' def phabsend(ui, repo, *revs, **opts):' | |||
|
1183 | 1183 | else: |
|
1184 | 1184 | # Nothing changed. But still set "newrevphid" so the next revision |
|
1185 | 1185 | # could depend on this one and "newrevid" for the summary line. |
|
1186 | newrevphid = querydrev(repo, b'%d' % revid)[0][b'phid'] | |
|
1186 | newrevphid = querydrev(repo.ui, b'%d' % revid)[0][b'phid'] | |
|
1187 | 1187 | newrevid = revid |
|
1188 | 1188 | action = b'skipped' |
|
1189 | 1189 | |
@@ -1398,7 +1398,7 b' def _prefetchdrevs(tree):' | |||
|
1398 | 1398 | return drevs, ancestordrevs |
|
1399 | 1399 | |
|
1400 | 1400 | |
|
1401 |
def querydrev( |
|
|
1401 | def querydrev(ui, spec): | |
|
1402 | 1402 | """return a list of "Differential Revision" dicts |
|
1403 | 1403 | |
|
1404 | 1404 | spec is a string using a simple query language, see docstring in phabread |
@@ -1449,7 +1449,7 b' def querydrev(repo, spec):' | |||
|
1449 | 1449 | key = (params.get(b'ids') or params.get(b'phids') or [None])[0] |
|
1450 | 1450 | if key in prefetched: |
|
1451 | 1451 | return prefetched[key] |
|
1452 |
drevs = callconduit( |
|
|
1452 | drevs = callconduit(ui, b'differential.query', params) | |
|
1453 | 1453 | # Fill prefetched with the result |
|
1454 | 1454 | for drev in drevs: |
|
1455 | 1455 | prefetched[drev[b'phid']] = drev |
@@ -1486,7 +1486,7 b' def querydrev(repo, spec):' | |||
|
1486 | 1486 | drevs, ancestordrevs = _prefetchdrevs(tree) |
|
1487 | 1487 | |
|
1488 | 1488 | # developer config: phabricator.batchsize |
|
1489 |
batchsize = |
|
|
1489 | batchsize = ui.configint(b'phabricator', b'batchsize') | |
|
1490 | 1490 | |
|
1491 | 1491 | # Prefetch Differential Revisions in batch |
|
1492 | 1492 | tofetch = set(drevs) |
@@ -1668,7 +1668,7 b' def phabread(ui, repo, spec, **opts):' | |||
|
1668 | 1668 | opts = pycompat.byteskwargs(opts) |
|
1669 | 1669 | if opts.get(b'stack'): |
|
1670 | 1670 | spec = b':(%s)' % spec |
|
1671 | drevs = querydrev(repo, spec) | |
|
1671 | drevs = querydrev(repo.ui, spec) | |
|
1672 | 1672 | readpatch(repo.ui, drevs, ui.write) |
|
1673 | 1673 | |
|
1674 | 1674 | |
@@ -1698,7 +1698,7 b' def phabupdate(ui, repo, spec, **opts):' | |||
|
1698 | 1698 | for f in flags: |
|
1699 | 1699 | actions.append({b'type': f, b'value': True}) |
|
1700 | 1700 | |
|
1701 | drevs = querydrev(repo, spec) | |
|
1701 | drevs = querydrev(repo.ui, spec) | |
|
1702 | 1702 | for i, drev in enumerate(drevs): |
|
1703 | 1703 | if i + 1 == len(drevs) and opts.get(b'comment'): |
|
1704 | 1704 | actions.append({b'type': b'comment', b'value': opts[b'comment']}) |
General Comments 0
You need to be logged in to leave comments.
Login now