Skip to content

Commit 055c3a7

Browse files
author
Konstantin
committed
fmt
1 parent 2f94d34 commit 055c3a7

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

src/rebdhuhn/graph_conversion.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,8 @@ def convert_table_to_graph(table: EbdTable) -> EbdGraph:
229229
)
230230
return EbdGraph(metadata=graph_metadata, graph=graph, multi_step_instructions=table.multi_step_instructions)
231231

232-
def _apply_workaround_to_issue_383(graph:DiGraph)->None:
232+
233+
def _apply_workaround_to_issue_383(graph: DiGraph) -> None:
233234
"""
234235
removes isolated hinweis nodes which are not connected to the graph, e.g. 'Es gibt 1..n Treffer'...
235236
Ideally we'd not create them at all, then we wouldn't have to remove them in a post processing step.
@@ -238,6 +239,7 @@ def _apply_workaround_to_issue_383(graph:DiGraph)->None:
238239
isolated = list(isolates(graph))
239240
graph.remove_nodes_from(isolated)
240241

242+
241243
def convert_empty_table_to_graph(metadata: EbdTableMetaData) -> EbdGraph:
242244
"""
243245
Converts an ebd section with no table to a graph to capture hints.

unittests/test_malo_ident.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ def test_e0594_svg_creation(snapshot: SnapshotAssertion) -> None:
2929
svg_code = Kroki().convert_dot_to_svg(dot_code)
3030
target_dir = Path(__file__).parent / "output"
3131
os.makedirs(target_dir, exist_ok=True)
32-
with open(target_dir / f"table_dot_svg_malo_ident_{graph.metadata.ebd_code}.svg", "w+", encoding="utf-8") as svg_file:
32+
with open(
33+
target_dir / f"table_dot_svg_malo_ident_{graph.metadata.ebd_code}.svg", "w+", encoding="utf-8"
34+
) as svg_file:
3335
svg_file.write(svg_code)
3436
assert dot_code == snapshot(name=f"table_dot_svg_malo_ident_{graph.metadata.ebd_code}")

0 commit comments

Comments
 (0)