Problem with MathOptInterface.jl @ 1.7.0

Does anyone encounter a crash on Julia 1.8.0 when using the latest version JuMP.jl and MathOptInterface.jl @ 1.7.0? The following pop-up messages are displayed on my computer running windows 11. However, when switched to MathOptInterface.jl @ 1.6.1, everything goes well.

Blockquote
Please submit a bug report with steps to reproduce this fault, and any error messages that follow (in their entirety). Thanks.
Exception: EXCEPTION_ACCESS_VIOLATION at 0x6542ded8 – jl_f_getfield at /cygdrive/c/buildbot/worker/package_win64/build/src\builtins.c:923
Blockquote

Give more information (complete stacktrace, …) and a reproducer, if possible.

2 Likes

Can you share a reproducible example? What code were you running when it happened?

1 Like

For instance, a piece of simple code like this:
import JuMP, GLPK
m = JuMP.Model(JuMP.optimizer_with_attributes(GLPK.Optimizer, “msg_lev” => GLPK.GLP_MSG_OFF))
JuMP.@variable(m, x)
JuMP.@constraint(m, x ≥ 0)
JuMP.@objective(m, Min, x)
JuMP.optimize!(m)

crash information:
Please submit a bug report with steps to reproduce this fault, and any error messages that follow (in their entirety). Thanks.
Exception: EXCEPTION_ACCESS_VIOLATION at 0x6542ded8 – jl_f_getfield at /cygdrive/c/buildbot/worker/package_win64/build/src\builtins.c:923
jl_f_getfield at /cygdrive/c/buildbot/worker/package_win64/build/src\builtins.c:923
pass_attributes at D:\Program Files\Julia.julia\packages\MathOptInterface\LqT2k\src\Utilities\copy.jl:66
default_copy_to at D:\Program Files\Julia.julia\packages\MathOptInterface\LqT2k\src\Utilities\copy.jl:494
copy_to at D:\Program Files\Julia.julia\packages\MathOptInterface\LqT2k\src\Bridges\bridge_optimizer.jl:451 [inlined]
optimize! at D:\Program Files\Julia.julia\packages\MathOptInterface\LqT2k\src\MathOptInterface.jl:86 [inlined]
optimize! at D:\Program Files\Julia.julia\packages\MathOptInterface\LqT2k\src\Utilities\cachingoptimizer.jl:316
unknown function (ip: 0000000000f22ae6)#optimize!#138 at D:\Program Files\Julia.julia\packages\JuMP\60Bnj\src\optimizer_interface.jl:185
optimize! at D:\Program Files\Julia.julia\packages\JuMP\60Bnj\src\optimizer_interface.jl:155
unknown function (ip: 0000000000f13706)jl_apply at /cygdrive/c/buildbot/worker/package_win64/build/src\julia.h:1838 [inlined]
do_call at /cygdrive/c/buildbot/worker/package_win64/build/src\interpreter.c:126
eval_value at /cygdrive/c/buildbot/worker/package_win64/build/src\interpreter.c:215
eval_stmt_value at /cygdrive/c/buildbot/worker/package_win64/build/src\interpreter.c:166 [inlined]
eval_body at /cygdrive/c/buildbot/worker/package_win64/build/src\interpreter.c:594
jl_interpret_toplevel_thunk at /cygdrive/c/buildbot/worker/package_win64/build/src\interpreter.c:750
jl_toplevel_eval_flex at /cygdrive/c/buildbot/worker/package_win64/build/src\toplevel.c:906
jl_toplevel_eval_flex at /cygdrive/c/buildbot/worker/package_win64/build/src\toplevel.c:850
ijl_toplevel_eval at /cygdrive/c/buildbot/worker/package_win64/build/src\toplevel.c:915 [inlined]
ijl_toplevel_eval_in at /cygdrive/c/buildbot/worker/package_win64/build/src\toplevel.c:965
eval at .\boot.jl:368 [inlined]
include_string at .\loading.jl:1428
include_string at D:\Program Files\Julia.julia\packages\Atom\BEJkS\src\utils.jl:286 [inlined]
#218 at D:\Program Files\Julia.julia\packages\Atom\BEJkS\src\eval.jl:121
withpath at D:\Program Files\Julia.julia\packages\CodeTools\VsjEq\src\utils.jl:30
unknown function (ip: 00000000010acc54)withpath at D:\Program Files\Julia.julia\packages\Atom\BEJkS\src\eval.jl:9
#217 at D:\Program Files\Julia.julia\packages\Atom\BEJkS\src\eval.jl:119
unknown function (ip: 00000000010abed3)with_logstate at .\logging.jl:511
with_logger at .\logging.jl:623 [inlined]
#216 at D:\Program Files\Julia.julia\packages\Atom\BEJkS\src\eval.jl:118 [inlined]
hideprompt at D:\Program Files\Julia.julia\packages\Atom\BEJkS\src\repl.jl:127

What happens when you run this?:

import JuMP, GLPK
m = JuMP.Model(GLPK.Optimizer)
JuMP.@variable(m, x)
JuMP.@constraint(m, x ≥ 0)
JuMP.MOI.get(m, JuMP.MOI.ListOfVariableAttributesSet())
1 Like

I just removed the package by “Pkg.rm(“MathOptInterface”)”, and reinstalled it. Now, everything is fine! Many thanks for your attention!