Error in solving simple SDP in Mosek+JuMP after updating related Julia packages (previously worked)

Dear All,

I recently updated some of my Julia packages related to optimization as follows:

[4076af6c] ↑ JuMP v0.21.10 ⇒ v0.22.1
[b8f27783] ↑ MathOptInterface v0.9.22 ⇒ v0.10.6
[1ec41992] ↑ MosekTools v0.9.4 ⇒ v0.10.0
[4076af6c] ↑ JuMP v0.21.10 ⇒ v0.22.1
[b8f27783] ↑ MathOptInterface v0.9.22 ⇒ v0.10.6
[1ec41992] ↑ MosekTools v0.9.4 ⇒ v0.10.0

Now after updating, I am getting error solving a very simple SDP, which I was able to solve without any problem prior to my update. My mosek version is 9.3.10 (the latest). The SDP is as follows:

using JuMP, MosekTools, Mosek, LinearAlgebra

N = 3

model = Model(optimizer_with_attributes(Mosek.Optimizer))

# construct G ⪰ 0
@variable(model, G[1:N, 1:N], PSD)

@variable(model, F[1:N-1] >= 0)

A = [1 2 3; 4 5 6; 7 8 9]

b = [7;8]

@constraint(model,  F'*b + tr(G) <= 0)

@objective(model, Min, sum(F) - tr(G))

optimize!(model)

p_star = objective_value(model)

G_star = value.(G)

F_star = value.(F)

The error I am getting is as follows:


MethodError: no method matching set_column_name(::Mosek.Task, ::MosekTools.MatrixIndex, ::String)
Closest candidates are:
  set_column_name(::Mosek.Task, !Matched::MosekTools.ColumnIndex, ::String) at C:\Users\shuvo\.julia\packages\MosekTools\Ryr4X\src\variable.jl:44
  set_column_name(!Matched::MosekTools.Optimizer, !Matched::MathOptInterface.VariableIndex, ::String) at C:\Users\shuvo\.julia\packages\MosekTools\Ryr4X\src\variable.jl:47
in eval at base\boot.jl:360 
in top-level scope at junk_7.jl:22
in optimize! at JuMP\2IF9U\src\optimizer_interface.jl:167
in optimize! at JuMP\2IF9U\src\optimizer_interface.jl:167 
in var"#optimize!#121" at JuMP\2IF9U\src\optimizer_interface.jl:195
in optimize! at MathOptInterface\eoIu0\src\Utilities\cachingoptimizer.jl:285
in optimize! at MathOptInterface\eoIu0\src\MathOptInterface.jl:80 
in copy_to at MathOptInterface\eoIu0\src\Bridges\bridge_optimizer.jl:421 
in #copy_to#7 at MathOptInterface\eoIu0\src\Bridges\bridge_optimizer.jl:421 
in default_copy_to at MathOptInterface\eoIu0\src\Utilities\copy.jl:438
in pass_attributes at MathOptInterface\eoIu0\src\Utilities\copy.jl:69
in _pass_attribute at MathOptInterface\eoIu0\src\Utilities\copy.jl:84
in set at MathOptInterface\eoIu0\src\Bridges\bridge_optimizer.jl:1327 
in set at MosekTools\Ryr4X\src\variable.jl:296 
in set_column_name at MosekTools\Ryr4X\src\variable.jl:48

I have no idea what is going on. The code ran without any problem before updating. Any tips/suggestions regarding how to avoid this issue will be much appreciated.

This looks like a bug in MosekTools.jl. Please open an issue.

Yes, I have done that. Thank you @odow .

1 Like

Link: Simple SDP fails to solve · Issue #80 · jump-dev/MosekTools.jl · GitHub

I replied to your issue with a suggestion for what to do next.