D2034: sshpeer: move handshake outside of sshpeer

indygreg (Gregory Szorc) phabricator at mercurial-scm.org
Mon Feb 5 12:04:42 EST 2018


indygreg marked an inline comment as done.
indygreg added inline comments.

INLINE COMMENTS

> lothiraldan wrote in sshpeer.py:422
> Nit: Could the except block could be replaced by a finally block?

No, because the pipes are used for the remainder of the connection.

I would like to switch peers to use context managers so we have stronger lifetimes for these pipes. But that will require a bit of changes throughout the code base. If someone were to write those patches, I'd review them. This is definitely the cycle to do it, as we're breaking all the APIs around the wire protocol.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D2034

To: indygreg, #hg-reviewers
Cc: lothiraldan, mercurial-devel


More information about the Mercurial-devel mailing list