# HG changeset patch # User Alex Gaynor # Date 1506700160 0 # Node ID 5326e4ef1dab0bb33f5262aa9e68491d115525fb # Parent 884b595f5195f8c1f13ca25ffe7c92c5a1becaea style: never put multiple statements on one line Differential Revision: https://phab.mercurial-scm.org/D905 diff -r 884b595f5195 -r 5326e4ef1dab mercurial/keepalive.py --- a/mercurial/keepalive.py Mon Oct 02 18:18:57 2017 +0100 +++ b/mercurial/keepalive.py Fri Sep 29 15:49:20 2017 +0000 @@ -135,7 +135,8 @@ del self._connmap[connection] del self._readymap[connection] self._hostmap[host].remove(connection) - if not self._hostmap[host]: del self._hostmap[host] + if not self._hostmap[host]: + del self._hostmap[host] finally: self._lock.release() @@ -621,7 +622,8 @@ f = fo.readline() if f: foo = foo + f - else: break + else: + break fo.close() m = md5(foo) print(format % ('keepalive readline', m.hexdigest())) diff -r 884b595f5195 -r 5326e4ef1dab mercurial/pure/bdiff.py --- a/mercurial/pure/bdiff.py Mon Oct 02 18:18:57 2017 +0100 +++ b/mercurial/pure/bdiff.py Fri Sep 29 15:49:20 2017 +0000 @@ -60,7 +60,8 @@ bin = [] p = [0] - for i in a: p.append(p[-1] + len(i)) + for i in a: + p.append(p[-1] + len(i)) d = difflib.SequenceMatcher(None, a, b).get_matching_blocks() d = _normalizeblocks(a, b, d) diff -r 884b595f5195 -r 5326e4ef1dab mercurial/pure/mpatch.py --- a/mercurial/pure/mpatch.py Mon Oct 02 18:18:57 2017 +0100 +++ b/mercurial/pure/mpatch.py Fri Sep 29 15:49:20 2017 +0000 @@ -75,7 +75,8 @@ # copy all the patches into our segment so we can memmove from them pos = b2 + bl m.seek(pos) - for p in bins: m.write(p) + for p in bins: + m.write(p) for plen in plens: # if our list gets too long, execute it diff -r 884b595f5195 -r 5326e4ef1dab mercurial/sshserver.py --- a/mercurial/sshserver.py Mon Oct 02 18:18:57 2017 +0100 +++ b/mercurial/sshserver.py Fri Sep 29 15:49:20 2017 +0000 @@ -127,7 +127,8 @@ r = impl() if r is not None: self.sendresponse(r) - else: self.sendresponse("") + else: + self.sendresponse("") return cmd != '' def _client(self): diff -r 884b595f5195 -r 5326e4ef1dab mercurial/util.py --- a/mercurial/util.py Mon Oct 02 18:18:57 2017 +0100 +++ b/mercurial/util.py Fri Sep 29 15:49:20 2017 +0000 @@ -1605,8 +1605,10 @@ ifp.close() ofp.close() except: # re-raises - try: os.unlink(temp) - except OSError: pass + try: + os.unlink(temp) + except OSError: + pass raise return temp