# Error with JuMP.model function

**URL:** https://discourse.julialang.org/t/error-with-jump-model-function/50190
**Category:** Optimization (Mathematical)
**Tags:** jump
**Created:** [November 15, 2020, 3:30pm UTC](https://discourse.julialang.org/t/error-with-jump-model-function/50190 "2020-11-15T15:30:41Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![erikbjornerem](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/erikbjornerem/32/19450_2.png) [@erikbjornerem](https://discourse.julialang.org/u/erikbjornerem)
#### Post date: [November 15, 2020, 3:30pm UTC](https://discourse.julialang.org/t/error-with-jump-model-function/50190/1 "2020-11-15T15:30:41Z")

</div>

Hi,

I’m relatively new to Julia and the JuMP package. The other day I also got the MathOptInterface package in order to export my LP model as a LP-file to be used in LPsolve by a fellow student. However after doing so I ran into an issue with JuMP. When I run the function call

m = Model(Clp.Optimizer)

I get the error:

ERROR: LoadError: MethodError: no method matching Model(::Type{Clp.Optimizer})  
Closest candidates are:  
Model(::Any, ::Any, ::Any, ::Any, ::Any, ::Any, ::Any, ::Any) at C:\Users.….julia\packages\JuMP\MsUSY\src\JuMP.jl:126  
Model(; caching\_mode, solver) at C:\Users.….julia\packages\JuMP\MsUSY\src\JuMP.jl:161  
Model(::MathOptInterface.AbstractOptimizer, ::Dict{MathOptInterface.ConstraintIndex,AbstractShape}, ::Set{Any}, ::Any, ::Any, ::Dict{Symbol,Any}, ::Int64, ::Dict{Symbol,Any}) at C:\Users.….julia\packages\JuMP\MsUSY\src\JuMP.jl:126

I am now unable to run any of my LP models and I have no idea why I get this error. Any suggestions on how to fix my issues with JuMP?

---

<div class="post-metadata">

### Author: ![odow](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/odow/32/28685_2.png) [@odow](https://discourse.julialang.org/u/odow)
#### Post date: [November 15, 2020, 9:37pm UTC](https://discourse.julialang.org/t/error-with-jump-model-function/50190/2 "2020-11-15T21:37:45Z")

</div>

You have an old version of JuMP.

Try:

```nohighlight
] add JuMP@0.21

```

You should see an error about a package incompatibility. Remove the offending package and try again.

I would encourage you to use a Pkg environment to ensure you have the minimal set of required packages, which minimizes these incompatibilities:  
[https://julialang.github.io/Pkg.jl/v1.5/environments/](https://julialang.github.io/Pkg.jl/v1.5/environments/)

---

<div class="post-metadata">

### Author: ![erikbjornerem](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/erikbjornerem/32/19450_2.png) [@erikbjornerem](https://discourse.julialang.org/u/erikbjornerem)
#### Post date: [November 16, 2020, 11:34am UTC](https://discourse.julialang.org/t/error-with-jump-model-function/50190/3 "2020-11-16T11:34:12Z")

</div>

Thank you odow!

] add JuMP@0.21 worked right away.

Previously I tried updating JuMP by using Pkg.update(“JuMP”). As that didn’t work I tried removing it and reinstalling it using Pkg.rm(“JuMP”) and Pkg.add(“JuMP”). Is there a reason this would not give me the newest update?
