Mercurial > public > mercurial-scm > hg
diff mercurial/graphmod.py @ 51686:493034cc3265
black: format the codebase with 23.3.0
The CI has moved to 23.3.0, which is the last version that supports 3.7
at runtime, so we should honor this change.
# skip-blame mass-reformating only
author | Rapha?l Gom?s <rgomes@octobus.net> |
---|---|
date | Thu, 18 Jul 2024 12:36:12 +0200 |
parents | d44e3c45f0e4 |
children | 7f0cb9ee0534 |
line wrap: on
line diff
--- a/mercurial/graphmod.py Thu Jul 18 12:03:29 2024 +0200 +++ b/mercurial/graphmod.py Thu Jul 18 12:36:12 2024 +0200 @@ -133,8 +133,7 @@ else: getconf = lambda rev: {} - for (cur, type, data, parents) in dag: - + for cur, type, data, parents in dag: # Compute seen and next if cur not in seen: seen.append(cur) # new head @@ -244,7 +243,7 @@ def _fixlongrightedges(edges): - for (i, (start, end)) in enumerate(edges): + for i, (start, end) in enumerate(edges): if end > start: edges[i] = (start, end + 1) @@ -265,7 +264,7 @@ def _drawedges(echars, edges, nodeline, interline): - for (start, end) in edges: + for start, end in edges: if start == end + 1: interline[2 * end + 1] = b"/" elif start == end - 1: @@ -381,7 +380,7 @@ this function can be monkey-patched by extensions to alter graph display without needing to mimic all of the edge-fixup logic in ascii() """ - for (ln, logstr) in graph: + for ln, logstr in graph: ui.write((ln + logstr).rstrip() + b"\n")