# Gurobi.jl precompile fails after upgrade

**URL:** https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990
**Category:** Optimization (Mathematical)
**Created:** [December 16, 2016, 12:59pm UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990 "2016-12-16T12:59:04Z")
**Posts on this page:** 11
**Page:** 1

<div class="post-metadata">

### Author: ![jesse](https://avatars.discourse-cdn.com/v4/letter/j/c77e96/32.png) [@jesse](https://discourse.julialang.org/u/jesse)
#### Post date: [December 16, 2016, 12:59pm UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/1 "2016-12-16T12:59:04Z")

</div>

Hi!

My worst fear got realized when I upgraded my Julia installation to the newest version:

```julia
julia> versioninfo()
Julia Version 0.6.0-dev.1562
Commit 3037157 (2016-12-14 07:11 UTC)
Platform Info:
  OS: Linux (x86_64-linux-gnu)
  CPU: Intel(R) Core(TM) i5-4440 CPU @ 3.10GHz
  WORD_SIZE: 64
  BLAS: libopenblas (USE64BITINT DYNAMIC_ARCH NO_AFFINITY Haswell)
  LAPACK: libopenblas64_
  LIBM: libopenlibm
  LLVM: libLLVM-3.7.1 (ORCJIT, haswell)

```

I then tried to test that the packages I use the most frequently are working: JuMP with Gurobi.jl.  
I tried loading Gurobi but I get a precompilation error:

```julia
julia> using Gurobi
INFO: Precompiling module Gurobi.
ERROR: LoadError: LoadError: UndefVarError: _major not defined
 in getlibversion() at /home/jesse/.julia/v0.6/Gurobi/src/grb_common.jl:49
 in include_from_node1(::String) at ./loading.jl:532
 in include(::String) at ./sysimg.jl:14
 in include_from_node1(::String) at ./loading.jl:532
 in include(::String) at ./sysimg.jl:14
 in anonymous at ./<missing>:2
 in eval(::Module, ::Any) at ./boot.jl:236
 in process_options(::Base.JLOptions) at ./client.jl:248
 in _start() at ./client.jl:335
while loading /home/jesse/.julia/v0.6/Gurobi/src/grb_common.jl, in expression starting on line 67
while loading /home/jesse/.julia/v0.6/Gurobi/src/Gurobi.jl, in expression starting on line 63
ERROR: Failed to precompile Gurobi to /home/jesse/.julia/lib/v0.6/Gurobi.ji.
 in compilecache(::String) at ./loading.jl:672
 in require(::Symbol) at ./loading.jl:453

```

Using Gurobi 7.0.1. Is there anything I can do? Seems like a variable \_major is not defined in the code. JuMP works fine, althought while loading it gives me warning that `WARNING: Base.take is deprecated.`

---

<div class="post-metadata">

### Author: ![dpsanders](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/dpsanders/32/3573_2.png) [@dpsanders](https://discourse.julialang.org/u/dpsanders)
#### Post date: [December 16, 2016, 1:00pm UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/2 "2016-12-16T13:00:34Z")

</div>

0.6 is not yet ready for non-broken use, in particular with packages.

---

<div class="post-metadata">

### Author: ![jesse](https://avatars.discourse-cdn.com/v4/letter/j/c77e96/32.png) [@jesse](https://discourse.julialang.org/u/jesse)
#### Post date: [December 16, 2016, 1:02pm UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/3 "2016-12-16T13:02:53Z")

</div>

Well thanks for the quick response, I’ll revert to 0.5.

---

<div class="post-metadata">

### Author: ![joehuchette](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/joehuchette/32/32_2.png) [@joehuchette](https://discourse.julialang.org/u/joehuchette)
#### Post date: [December 16, 2016, 2:34pm UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/4 "2016-12-16T14:34:30Z")

</div>

We’d definitely accept PRs to fix compatibility with 0.6-dev, but while things are still changing and breaking, tracking master is not a high priority for us.

-Joey

---

<div class="post-metadata">

### Author: ![kristoffer.carlsson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kristoffer.carlsson/32/22_2.png) [@kristoffer.carlsson](https://discourse.julialang.org/u/kristoffer.carlsson)
#### Post date: [December 16, 2016, 2:34pm UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/5 "2016-12-16T14:34:47Z")

</div>

If package breaking when upgrading to the latest master branch of an open source project is your “worst fear”, I envy your calm life 🙂

---

<div class="post-metadata">

### Author: ![ChrisRackauckas](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chrisrackauckas/32/77_2.png) [@ChrisRackauckas](https://discourse.julialang.org/u/ChrisRackauckas)
#### Post date: [December 16, 2016, 8:07pm UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/6 "2016-12-16T20:07:58Z")

</div>

This isn’t the first time this has come up. With many new users I’ve tracked down issues to being due to them using v0.6 since they want to try out the latest features. Maybe the downloads page [Download Julia](http://julialang.org/downloads/) should be more explicit. It currently says:

> However, because Julia is under heavy development, you may be unlucky and get a build with a serious bug, or one which breaks existing packages.

But maybe it should go a little further, something along the lines of:

> However, because Julia is under heavy development, you may be unlucky and get a build with a serious bug. Also, many packages are not compatible with this unreleased version, and thus this version is only advised for developers looking to update packages before release.

?

---

<div class="post-metadata">

### Author: ![dpsanders](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/dpsanders/32/3573_2.png) [@dpsanders](https://discourse.julialang.org/u/dpsanders)
#### Post date: [December 17, 2016, 12:20am UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/7 "2016-12-17T00:20:44Z")

</div>

I think “you may be unlucky” is too weak. It’s more like “things will definitely be broken, especially packages, and no-one will be interested in fixing them until such and such a date, so please don’t even bother trying to use it”. (Not the suggested words for the website!)

---

<div class="post-metadata">

### Author: ![ChrisRackauckas](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chrisrackauckas/32/77_2.png) [@ChrisRackauckas](https://discourse.julialang.org/u/ChrisRackauckas)
#### Post date: [December 17, 2016, 12:52am UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/8 "2016-12-17T00:52:46Z")

</div>

> [@dpsanders](#):
>
> I think “you may be unlucky” is too weak. It’s more like “things will definitely be broken, especially packages, and no-one will be interested in fixing them until such and such a date, so please don’t even bother trying to use it”. (Not the suggested words for the website!)

Maybe it should say something like “the nightly builds are for developer previews and not intended for normal use. You can expect many packages to not work with this version.” ?

---

<div class="post-metadata">

### Author: ![dpsanders](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/dpsanders/32/3573_2.png) [@dpsanders](https://discourse.julialang.org/u/dpsanders)
#### Post date: [December 17, 2016, 4:02am UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/9 "2016-12-17T04:02:13Z")

</div>

That’s pretty good. “to not” → “not to”?

---

<div class="post-metadata">

### Author: ![ChrisRackauckas](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chrisrackauckas/32/77_2.png) [@ChrisRackauckas](https://discourse.julialang.org/u/ChrisRackauckas)
#### Post date: [December 17, 2016, 7:41am UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/10 "2016-12-17T07:41:55Z")

</div>

I put in a PR with this last change included:

[https://github.com/JuliaLang/julialang.github.com/pull/472](https://github.com/JuliaLang/julialang.github.com/pull/472)

---

<div class="post-metadata">

### Author: ![jesse](https://avatars.discourse-cdn.com/v4/letter/j/c77e96/32.png) [@jesse](https://discourse.julialang.org/u/jesse)
#### Post date: [December 17, 2016, 2:38pm UTC](https://discourse.julialang.org/t/gurobi-jl-precompile-fails-after-upgrade/990/11 "2016-12-17T14:38:56Z")

</div>

I admit I was being overly dramatic 😏 The truth is that I forgot to checkout my local repository to 0.5 before building.
