Problems during package updating in Julia

package

#1

Hi! I’m somewhat new in using Julia and I’m currently trying to update the DataFrames package through the Pkg.update() method. At first, I got an error saying that the “fixed packages introduce conflicting requirements”. After a quick search I’ve tried to follow this solution I’ve found in StackOverflow by running Pkg.rm(“BinDeps”).

Now, I’m getting the following error message after trying to update DataFrames again:

INFO: Package DataFrames was set to version 0.10.0, but a higher version 0.11.3 exists.
      The update is prevented by explicit requirements constraints. Edit your REQUIRE file to change this.
INFO: No packages to install, update or remove

I’ve tried to add the BinDeps package again but it changed nothing, so I tried to edit my REQUIRE file using Pkg.edit() and got another error: ERROR: set the EDITOR environment variable to an edit command.

And I just simply can’t figure out what to do next (lol). Can I get some help there?


#2

It’s hard to answer in general, but you probably have one or more packages that were fixed using Pkg.pin() at some point. It will be easier to see what’s going on if you post the output of Pkg.status(), which will show all of your installed packages and their various versions.

You can set environment variables from within Julia using ENV["variablename"] = "variablevalue". You can make that setting permanent for all Julia sessions by adding such a line to a file named .juliarc.jl in your home directory.


#3

The current package manager isn’t very good and doing perfectly reasonable things can result in conflicts like this. Just so you know that there is light at the end of the tunnel, the package system will be completely overhauled in the (imminently) upcoming Julia 0.7.

In the meantime, sometimes I find it useful to simply use git and clone the packages you want directly into /home/user/.julia/v0.6.


#4

This is the current output I’m getting.

160 required packages:
 - AbstractFFTs                  0.2.0
 - Atom                          0.6.1
 - AutoGrad                      0.0.7
 - AutoHashEquals                0.1.1
 - AxisAlgorithms                0.1.6
 - AxisArrays                    0.1.4
 - BinDeps                       0.8.2
 - Blink                         0.5.3
 - Blosc                         0.3.0
 - BufferedStreams               0.3.3
 - BusinessDays                  0.7.1
 - CSV                           0.1.4
 - Calculus                      0.2.2
 - CatIndices                    0.0.2
 - CategoricalArrays             0.1.6
 - Clustering                    0.8.0
 - CodeTools                     0.4.6
 - Codecs                        0.3.0
 - ColorTypes                    0.5.2
 - ColorVectorSpace              0.4.4
 - Colors                        0.7.4
 - Combinatorics                 0.4.1
 - Compat                        0.28.0
 - Compose                       0.5.3
 - ComputationalResources        0.0.2
 - Conda                         0.5.3
 - Contour                       0.3.0
 - CoordinateTransformations     0.4.1
 - CoupledFields                 0.0.1
 - CustomUnitRanges              0.0.4
 - DBAPI                         0.1.0
 - DSP                           0.3.2
 - Dagger                        0.2.0
 - DataArrays                    0.6.2
 - DataFrames                    0.10.0
 - DataStreams                   0.1.3
 - DataStructures                0.6.0
 - DecFP                         0.3.0
 - DecisionTree                  0.6.1
 - DiffBase                      0.2.0
 - Distances                     0.4.1
 - Distributions                 0.14.2
 - DualNumbers                   0.3.0
 - FFTViews                      0.0.2
 - FFTW                          0.0.3
 - FileIO                        0.5.1
 - FixedPointNumbers             0.3.9
 - Formatting                    0.2.1
 - ForwardDiff                   0.4.2
 - GLM                           0.7.0
 - GZip                          0.3.0
 - Gadfly                        0.6.3
 - Glob                          1.1.1
 - Graphics                      0.2.0
 - HDF5                          0.8.2
 - HTTPClient                    0.2.1
 - Hexagons                      0.1.0
 - Hiccup                        0.1.1
 - HttpCommon                    0.2.7
 - HttpParser                    0.3.0
 - HttpServer                    0.2.0
 - HypothesisTests               0.5.1
 - IJulia                        1.5.1
 - IdentityRanges                0.0.1
 - ImageAxes                     0.3.1
 - ImageCore                     0.4.0
 - ImageFiltering                0.1.4
 - ImageMetadata                 0.2.3
 - ImageTransformations          0.3.1
 - Images                        0.11.0
 - IndexedTables                 0.2.1
 - IndirectArrays                0.1.1
 - Interact                      0.4.5
 - Interpolations                0.6.2
 - IntervalSets                  0.1.1
 - IterTools                     0.1.0
 - Iterators                     0.3.1
 - JDBC                          0.2.0
 - JLD                           0.6.11
 - JSON                          0.13.0
 - JavaCall                      0.5.1
 - JuMP                          0.17.1
 - JuliaWebAPI                   0.3.1
 - Juno                          0.3.0
 - KernelDensity                 0.3.2
 - Knet                          0.8.3
 - LNR                           0.0.2
 - LaTeXStrings                  0.2.1
 - Lazy                          0.11.7
 - LegacyStrings                 0.2.2
 - Libz                          0.2.4
 - LightGraphs                   0.9.4
 - LightXML                      0.5.0
 - LineSearches                  0.1.5
 - Loess                         0.3.0
 - Logging                       0.3.1
 - MLBase                        0.7.0
 - MNIST                         0.0.2
 - MacroTools                    0.3.7
 - MappedArrays                  0.0.7
 - MathProgBase                  0.6.4
 - MbedTLS                       0.4.5
 - Measures                      0.1.0
 - Media                         0.3.0
 - Mustache                      0.1.4
 - Mux                           0.2.3
 - NaNMath                       0.2.6
 - NamedArrays                   0.6.1
 - NamedTuples                   4.0.0
 - NearestNeighbors              0.3.0
 - Nettle                        0.3.0
 - NullableArrays                0.1.1
 - ODBC                          0.5.2
 - OffsetArrays                  0.3.0
 - Optim                         0.7.8
 - PDMats                        0.7.0
 - PaddedViews                   0.1.0
 - Parameters                    0.7.2
 - ParserCombinator              1.7.11
 - Plots                         0.14.2
 - Polynomials                   0.1.5
 - PooledArrays                  0.1.1
 - PositiveFactorizations        0.0.4
 - Primes                        0.1.3
 - ProtoBuf                      0.4.0
 - PyCall                        1.14.0
 - PyPlot                        2.3.2
 - QuadGK                        0.1.2
 - QuantEcon                     0.12.1
 - RCall                         0.7.3
 - RangeArrays                   0.2.0
 - Ratios                        0.1.0
 - Reactive                      0.5.2
 - Reexport                      0.0.3
 - Requests                      0.5.0
 - Requires                      0.4.3
 - ReverseDiffSparse             0.7.3
 - Rmath                         0.1.7
 - Roots                         0.4.0
 - Rotations                     0.5.0
 - SHA                           0.3.3
 - SIUnits                       0.1.0
 - ScikitLearnBase               0.3.0
 - ShowItLikeYouBuildIt          0.0.1
 - Showoff                       0.1.1
 - SimpleTraits                  0.5.0
 - SortingAlgorithms             0.1.1
 - SpecialFunctions              0.2.0
 - StaticArrays                  0.6.1
 - StatsBase                     0.17.0
 - StatsFuns                     0.5.0
 - TexExtensions                 0.1.0
 - TextParse                     0.1.6
 - TiledIteration                0.0.2
 - Tokenize                      0.1.8
 - URIParser                     0.1.8
 - WeakRefStrings                0.2.0
 - WebSockets                    0.2.3
 - WoodburyMatrices              0.2.2
 - ZMQ                           0.4.3
5 additional packages:
 - LibCURL                       0.2.2
 - NLSolversBase                 2.1.3
 - PlotThemes                    0.2.0
 - PlotUtils                     0.4.4
 - RecipesBase                   0.2.3

#5

Ah, I see. It looks like you’re using JuliaPro, which ships with a very specific set of required package versions. I’m afraid I don’t know what the recommended way to upgrade packages in JuliaPro is (after all, the whole point of JuliaPro was to provide a specific, coherent set of package versions nicely bundled into an IDE).

To see why this is happening, you can look at your REQUIRE file, which you can find inside the directory reported by Pkg.dir().

If you don’t need JuliaPro but just want to try the new DataFrames, you can always just install Julia itself (not JuliaPro) and then do Pkg.add("DataFrames").


#6

I know basically nothing about JuliaPro, but maybe just editing the file “.julia/v0.6/REQUIRE”, as suggested in hte INFO message, could be enough. For example, if DataFrames has an upper bound set there, simply removing it could suffice.

If you don’t want to edit the REQUIRE file directly, even just doing Pkg.rm("DataFrames") and then Pkg.add("DataFrames") could work, since that would remove any bounds on the package.


#7

Yeah, that may work. I’m concerned that the explicit version bounds on all of the other packages (including the dependencies of DataFrames) might prevent it from upgrading all the way, though.