From 7166a2a10d254f9e633818d3fd26c0c8dd13f7fe Mon Sep 17 00:00:00 2001 From: Joshua Harlow Date: Thu, 22 May 2014 12:18:41 -0700 Subject: [PATCH] Fix error string interpolation The values were not correctly being interpolated into the value error that is thrown when merging graphs together and they have overlapping nodes. Fix this by correctly interpolating and expanding the messaging/reason why we do not support overlapping graphs. Change-Id: Iff29f793c7dfd6b39a4936c7f4f31fd660262ca6 --- taskflow/types/graph.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/taskflow/types/graph.py b/taskflow/types/graph.py index f6759127..358f018a 100644 --- a/taskflow/types/graph.py +++ b/taskflow/types/graph.py @@ -113,7 +113,8 @@ def merge_graphs(graphs, allow_overlaps=False): overlaps = graph.subgraph(g.nodes_iter()) if len(overlaps): raise ValueError("Can not merge graph %s into %s since there " - "are %s overlapping nodes" (g, graph, + "are %s overlapping nodes (and we do not " + "support merging nodes)" % (g, graph, len(overlaps))) # Keep the target graphs name. name = graph.name