From 46e50600534f4038953af2672cb5dd4d6dec0c62 Mon Sep 17 00:00:00 2001 From: Benjamin Lorenz Date: Mon, 12 Feb 2024 11:56:30 +0100 Subject: [PATCH] mcf: add workaround to avoid hang during tropical median needed until next polymake release. somehow the system call behaves slightly different inside julia and needs -q to quit automatically. --- src/Polymake.jl | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/Polymake.jl b/src/Polymake.jl index 986ba4a7..8d3d43bb 100644 --- a/src/Polymake.jl +++ b/src/Polymake.jl @@ -267,6 +267,13 @@ function __init__() application("polytope") shell_execute("require LPparser;") + # workaround until next polymake release to make sure mcf does not get stuck + Polymake.shell_execute(raw""" + if (application("graph")->configured->{"mcf.rules"} > 0) { + $mcf = "$mcf -q" unless ($mcf =~ / -q/); + } + """) + for app in call_function(:common, :startup_applications) application(app) end