This is an archive of the discontinued Mercurial Phabricator instance.

wireproto: remove support for local results in @batchable (API)
ClosedPublic

Authored by indygreg on Aug 10 2017, 2:47 AM.

Details

Summary

@peer.batchable decorated generator functions have two forms:

yield value, None

and

yield args, future
yield value

These forms have been present since the decorator was introduced.

There are currently no in-repo consumers of the first form. So this
commit removes support for it.

Note that remoteiterbatcher.submit() asserts the 2nd form. And
b6e71f8af5b8 removed the last user of remotebatcher, forcing everyone
to remoteiterbatcher. So anything relying on this in the wild would
have been broken since b6e71f8af5b8.

.. api::

@peer.batchable can no longer emit local values

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

indygreg created this revision.Aug 10 2017, 2:47 AM
This revision was automatically updated to reflect the committed changes.
yuja added a subscriber: yuja.Aug 13 2017, 2:31 AM
yuja added inline comments.
mercurial/peer.py
99

Perhaps this could be deleted too.