From 719339657d4b6e04535d2f777ed6e1b595bf5538 Mon Sep 17 00:00:00 2001 From: 0penBrain <48731257+0penBrain@users.noreply.github.com> Date: Thu, 27 Apr 2023 12:34:45 +0200 Subject: [PATCH] Sheet: display an error in console when a cyclic dependency is detected --- src/Mod/Spreadsheet/App/Sheet.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Mod/Spreadsheet/App/Sheet.cpp b/src/Mod/Spreadsheet/App/Sheet.cpp index c773a3daca..e4f2288205 100644 --- a/src/Mod/Spreadsheet/App/Sheet.cpp +++ b/src/Mod/Spreadsheet/App/Sheet.cpp @@ -1005,8 +1005,9 @@ DocumentObjectExecReturn *Sheet::execute(void) std::list make_order; try { boost::topological_sort(graph, std::front_inserter(make_order)); - } catch (std::exception&) { + } catch (std::exception&) { //TODO: evaluate using a more specific exception (not_a_dag) // Cycle detected; flag all with errors + Base::Console().Error("Cyclic dependency detected in spreadsheet : %s\n", *pcNameInDocument); std::ostringstream ss; ss << "Cyclic dependency"; int count = 0;