# HG changeset patch # User Yuya Nishihara # Date 1441632419 -32400 # Node ID f22f3ff3cfae60c7bafd4f9b544060ef474a1561 # Parent bfdc96f223210867f0f6752700e16eddf2c9224a client: extract stub to read server's stderr on close() New _close() function will return (returncode, stderr) pair so that detailed error message can be obtained. diff -r bfdc96f22321 -r f22f3ff3cfae hglib/client.py --- a/hglib/client.py Tue Sep 01 17:03:10 2015 -0500 +++ b/hglib/client.py Mon Sep 07 22:26:59 2015 +0900 @@ -200,6 +200,9 @@ Attempting to call any function afterwards that needs to communicate with the server will raise a ValueError. """ + return self._close() + + def _close(self): self.server.stdin.close() self.server.wait() ret = self.server.returncode