I am using Julia 1.5, but for some reason when I look at Conda root environment in Julia, it points to an old installation, even though it has been uninstalled. Whenever I install anything through Conda they are installed in the wrong location. Is there any way I can update/change this ROOTENV path?
I think I had a very similar issue lately after manually changing the JULIA_DEPOT_PATH environment variable. The solution would be to locate your JULIA_DEPOT_PATH (if it is not set then it will be the default; in your case under Windows this would be something like C:\\Users\\akahs\\.julia I assume; not sure about JuliaPro though^^).
In this folder you’ll find two deps.jl files created by Conda.jl. They are located under:
%JULIA_DEPOT_PATH%\conda\deps.jl
%JULIA_DEPOT_PATH%\packages\Conda\{some numbers+characters}\deps\deps.jl (<-- this one is the actually important one)
These files were created during the build phase of the Conda.jl package and essentially store the location of the JULIA_DEPOT_PATH at that point in time to maintain a stable reference to that location. Ever after, this path simply gets loaded by Conda.jl, ignoring any other changes to the system. I don’t fully understand the reasoning behind this and I think it is a flawed behavior, since it means that any change to the JULIA_DEPOT_PATH will break the Conda.jl installation. IMHO Conda.jl should always use the current JULIA_DEPOT_PATH unless explicitly told otherwise. You can have a look into your deps.jl files and confirm that they are indeed pointing to the old path.
This would be the solution to your problem then:
Delete both the deps.jl files
Start Julia and run Pkg.build("Conda") or type ]build Conda
Afterwards Conda will have to reinstall quite a few python packages but in the end everything should be in its “default” location again.
I also opened a GitHub issue on this matter but it did not get any traction so far. If you can confirm this was also the problem in your case I would bump it over there: https://github.com/JuliaPy/Conda.jl/issues/183
Thanks! It was indeed the problem. Don’t understand how it was setup this way. In my case it’s probably because I used JuliaPro before so the Conda root path was kept there, but it really shouldn’t be.