JuMP installation issue in Julia v1.6

If you have the Julia 1.5 and Julia 1.6 binaries and you just alternate between calling one and the other then both are writing to the same Julia folder in your PC (where the packages are saved together with the REPL history and things like that). So it is expected that they may affect each other, but I am not sure to what extent, and if it is entirely safe to just alternate between binaries like that. I have always kept a different Julia folder for each version and before I start calling a version I often do not use I move my current ~/.julia to ~/.julia-OLD-VERSION-NUMBER and either let the binary create a new folder or move a folder for that version I saved back to that place.

What’s the version of Zlib_jll showing when you add JuMP the first time in 1.6?

Are you on a work/university network? Julia 1.6 changed how things are downloaded, and there may be some issues with firewalls, etc.

Hmmm…I would have thought the binaries address handled similarly to the packages themselves in the manifest, so that hypothetically I could have two different binary versions depending on which packed version in using.

Is it not possible for Ipopt.jl (for example) to come out with a new binary (for whatever reason) so that even if I use the same Julia version, I’m still referring to different binary dependencies?

That’s for the idea about renaming the .julia folder. I specifically did a fair amount on reading in updating Julia (this was my first time), and the consensus server to be that this sort of thing is not necessary. But my experience send to suggest otherwise :slight_smile:

I’m not sure unfortunately, I can run the test again tomorrow.

There are several dependencies that area failing though, not just that one. I also had a similar issue when trying to add Ipopt.

This was done from my home network, so no firewall or anything like that.

Oh, I also tried deleting the complied folder in my ~/.julia folder, but that didn’t seem to make any difference either.

In general, the process to update Julia is to download new binary from julialang.org, and that’s it. You don’t need to mess with ~/.julia.

I would try again, but make sure you delete /tmp/Project.toml and /tmp/Manifest.toml first. Problems can arise if you instantiate a Julia 1.6 environment in a folder containing a Manifest from Julia 1.5.

3 Likes

Interesting. This is infact exactly what I did following this thread:

Is the problem then that I not only copied but then also ran:

@v1.6 pkg> instantiate

If that’s the case, what is the correct way to transfer packages from the base environment of one version to the next?

You can copy over only the Project file (leave the manifest) and then do instantiate. Some changes have unfortunately made manifests from e.g. 1.5 incompatible with 1.6.

1 Like

Got it. That make sense.

Would you recommend reinstalling Julia 1.6, or can I simply remove the Projetct.toml and Manifest.toml from the v1.6 environment?

No need to reinstall Julia. Just remove the Manifest and do instantiate and it should hopefully work fine.

1 Like

Would ]update do just the same thing as removing Manifest+Instantiate? (Plus added bonus of keeping non-registered added packages and pinned indications?)?

I do not think so. Update probably looks at the Manifest (to check if it needs to do any work or not) and if the Manifest formats are incompatible there a chance you will get a problem this moment. If you check the code of Pkg.update it calls prune_manifest and other methods that seem to read from an existing Manifest (if it exists).

But in case of 1.5 → 1.6, there is no format incompatibilities AFAIK, only the fact that some jll that were previously independents are now embedded in Julia1.6 as stdlibs. So the issue is only to update those jll to the right ones?
Possibly I should have said ]resolve that update thé dependencies (while ]update goes to the latest ones) - in any case, ]update worked for me in my similar trouble cases.

Hm, it might be that 1.5 → 1.6 is ok but that 1.6 → 1.5 is the really bad case actually. I am not sure.

This seems to have been the issue.

I deleted my v1.6 Manifest.toml and ran resolve and then instantiate (leaving out the resolve led to Errors since I had missing dependencies in the (non existent) Manifest).

When I now repeat my original “Step 1” everything works.

Thanks for the help!

Hi I am teaching a class and my students are having the problem that attempting to add JuMP just hangs for Windows users [Mac users are fine] in the latest Julia 1.6.

Does anyone have any ideas?

Thanks

Could you maybe include the REPL output up to the point where it hangs?

My issue was not with hanging but with errors, and that was caused by mixing Julia 1.5 manifest with Julia 1.6.

If your students are installing a clean version of Julia 1.6 from the website and then doing ]add JuMP it should work just fine (I’ve done it several times in several windows machines)

1 Like

Please prefer to open a new post if you have a related question, rather than posting on a issue that was previously solved.

Does this only happen with JuMP? Have they tried other packages?

Thanks. There was no output - it just hung without anything. I’m sorry if this is unrelated, but I wondered if two difficulties installing the same release of the same package might be related. Also, I know that it is impossible to troubleshoot without output, but I wondered whether others had experienced the same issue [apparently not - thanks very much for checking!]

If it didn’t even output the message saying that it’s updating the registry index, then I’d suspect there is something wrong with the Julia installation itself and second the question about what happens with other packages.

1 Like

OK - thanks very much. I’ll pursue that angle.

Problem solved!!! For some reason, adding from Jupyter Notebook did not work, but adding from the REPL was fine (I have come across this once before, but I thought it was a ‘once’off’)