Open blegat opened 2 years ago
I think I have a fix for this issue, but it seems to introduce another one. A wild guess is that quadratic objectives are now reformulated into an vector affine expression, and something breaks. Any hints:
test_quadratic_duplicate_terms: Test Failed at /home/runner/.julia/packages/MathOptInterface/4g9vU/src/Test/test_quadratic.jl:235
Expression: obj2 ≈ MOI.get(model, MOI.ObjectiveFunction{MOI.ScalarQuadraticFunction{T}}())
Evaluated: 0.0 + 0.0 MOI.VariableIndex(1) + 0.0 MOI.VariableIndex(2) + 0.0 MOI.VariableIndex(3) - 2.0 MOI.VariableIndex(1)² - 1.0 MOI.VariableIndex(1)*MOI.VariableIndex(2) - 1.0 MOI.VariableIndex(1)*MOI.VariableIndex(2) - 2.0 MOI.VariableIndex(2)² - 2.0 MOI.VariableIndex(2)*MOI.VariableIndex(3) - 1.0 MOI.VariableIndex(3)² - 1.0 MOI.VariableIndex(3)² ≈ 0.0
Stacktrace:
[1] test_quadratic_duplicate_terms(model::MathOptInterface.Bridges.LazyBridgeOptimizer{MosekTools.Optimizer}, config::MathOptInterface.Test.Config{Float64})
@ MathOptInterface.Test ~/.julia/packages/MathOptInterface/4g9vU/src/Test/test_quadratic.jl:235
[2] macro expansion
@ ~/.julia/packages/MathOptInterface/4g9vU/src/Test/Test.jl:235 [inlined]
[3] macro expansion
@ /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.6/Test/src/Test.jl:1151 [inlined]
[4] runtests(model::MathOptInterface.Bridges.LazyBridgeOptimizer{MosekTools.Optimizer}, config::MathOptInterface.Test.Config{Float64}; include::Vector{String}, exclude::Vector{String}, warn_unsupported::Bool, exclude_tests_after::VersionNumber)
@ MathOptInterface.Test ~/.julia/packages/MathOptInterface/4g9vU/src/Test/Test.jl:230
I have commented it out since it does not work, it gives a MethodError https://github.com/jump-dev/MosekTools.jl/blob/53ede41977b8ef5d604b03643875329acc601b86/src/constraint.jl#L773-L790 https://github.com/jump-dev/MosekTools.jl/blob/53ede41977b8ef5d604b03643875329acc601b86/test/runtests.jl#L79-L80
cc @ulfworsoe