Closed odow closed 1 year ago
So I added this method:
# TODO(odow): why is this needed for v1.9?
function JuMP.check_belongs_to_model(
v::InfiniteVariableRef,
model::InfiniteModel,
)
if JuMP.owner_model(v) !== model
throw(JuMP.VariableNotOwned(v))
end
return
end
Which is just the method it was trying to call in JuMP:
So this feels like a bug in Julia. But it looks like you're testing on nightly, so I don't understand what happened.
I came to the same conclusion (see https://github.com/infiniteopt/InfiniteOpt.jl/pull/314#issuecomment-1543331721). I also have no idea why this is happening. And I checked the last few nightly runs, they all ran without issue...
So perhaps it was a bug that was fixed and not back ported to 1.9?
So perhaps it was a bug that was fixed and not back ported to 1.9?
This seems the most plausible.
Or maybe it's a bug in Julia that only shows with the new version of JuMP for some reason...
Trying to debug https://github.com/jump-dev/JuMP.jl/pull/3350#issuecomment-1542915469, using my printing PR here: https://github.com/infiniteopt/InfiniteOpt.jl/pull/314.
But I'm going crazy.
I've edited the code in
point_variables.jl
to print what's happening:When the function is called. No error is thrown. When you eval in the REPL, an error is thrown. Ideas???