We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bc47e64 commit f76c973Copy full SHA for f76c973
.vscode/settings.json
@@ -91,6 +91,5 @@
91
"Yinyu",
92
"Zentrum",
93
"Zuse"
94
- ],
95
- "julia.environmentPath": "e:\\Repos\\MSR\\OpticalCompute\\AOCoptimizer.jl\\notebooks"
+ ]
96
}
src/init.jl
@@ -9,8 +9,13 @@ module MOI
9
function __init()
10
__modules = Base.loaded_modules_array()
11
__index_of_jump_ext = findfirst(x -> nameof(x) == :JuMPExt, __modules)
12
- __jump_ext = __modules[__index_of_jump_ext]
13
- Optimizer[] = __jump_ext.Optimizer
+ if __index_of_jump_ext === nothing
+ # JuMPExt is not loaded, leaving value to `nothing`
14
+ Optimizer[] = nothing
15
+ else
16
+ __jump_ext = __modules[__index_of_jump_ext]
17
+ Optimizer[] = __jump_ext.Optimizer
18
+ end
19
end
20
21
0 commit comments