IPOPT suppress output file generation

@nico, you wrote Error with Ipopt.jl and ipopt.out file

Just so you know, I get the same issue also when I call IPOPT from JuMP.

Do you have a reproducible example?

I believe it is related to some recent updates, probably of Ipopt.jl

This is not a bug in Ipopt.jl, and there are no revelvant recent changes. OpenIpoptOutputFile calls the C API directly: Ipopt.jl/src/C_wrapper.jl at 801b6a0a055f79bbf5d785f80f9ba9cdb2333ec9 · jump-dev/Ipopt.jl · GitHub

If this is an issue, it is an issue in the upstream coin-or/Ipopt.

I am not sure that the fact that the output file is held by a process happens

Agreed. My PR is a different fix. But I’m not even sure if it is the right fix, because I cannot reproduce the file lock on macOS.

My guess is that issue is that the file is manually opened. It won’t be closed until FreeIpoptProblem is called, which won’t happen until the prob is freed by the garbage collector.

The default for the file_append option is “no”, so two problems cannot write to the same file.