From 66fa70e7efff36ac1b4b52141e5471c4fb0ae267 Mon Sep 17 00:00:00 2001 From: Katherine Mantel Date: Tue, 25 Jun 2024 21:26:41 +0000 Subject: [PATCH] utilities: output_graph_image: use os.path.extsep instead of . --- src/graph_scheduler/utilities.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/graph_scheduler/utilities.py b/src/graph_scheduler/utilities.py index 33496dc..47b6d7d 100644 --- a/src/graph_scheduler/utilities.py +++ b/src/graph_scheduler/utilities.py @@ -2,6 +2,7 @@ import functools import inspect import logging +import os import weakref from typing import Callable, Dict, Hashable, List, Set, Union @@ -230,7 +231,7 @@ def output_graph_image( - Python pydot: pip install pydot """ if filename is None: - filename = f'graph-scheduler-figure-{id(graph)}.{format}' + filename = f'graph-scheduler-figure-{id(graph)}{os.path.extsep}{format}' if not isinstance(graph, nx.Graph): graph = dependency_dict_to_networkx_digraph(graph)