I only wrote "using" and already fell into trouble


#1

I am using Julia 5.2 in the Atom environment. Coming from the C++ background. What makes me upset are: (1) frequent cryptic warnings and (2) inconsistent behaviour between consecutive runs of a program. Here is a minimal scenario for (1):

using DataArrays
using DataFrames
using MultivariateStats

I then use “Run File” and get:

WARNING: Method definition 
describe(AbstractArray) in module StatsBase at C:\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\Users\carbon\AppData\Local\JuliaPro-0.5.2.1\pkgs-0.5.2.1\v0.5\StatsBase\src\scalarstats.jl:573 overwritten in module DataFrames at C:\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\Users\carbon\AppData\Local\JuliaPro-0.5.2.1\pkgs-0.5.2.1\v0.5\DataFrames\src\abstractdataframe\abstractdataframe.jl:407.

Am I doing something wrong or is it just a bug in Julia itself?

(2) Another problem that I am having is inconsistent behaviour between consecutive program runs. Is it normal that I have some program working, but after some manipulation in the environment, that program stops to work? Right now I am just having “transform” function stopped to work:

LoadError: UndefVarError: transform not defined

I think I only tried to install and update some package since it was working before, but the program stayed the same.


#2

The first one is a issue in the two packages. I agree it’s annoy but I can’t see why it’s cryptic. The error message is pretty clearly saying that a method got overwritten and also the location of the original and new definition.

Upgrading packages can certainly change API so if you call that manipulation in the environment then yes it can make code not working anymore. Usually you need to check the package doc for what to do. (assuming no warning is printed about anything related).


#3

The alarming number of backslashes is probably a bug, though. Does that happen outside the Atom environment, and also with the release candidate version from https://julialang.org/downloads/ ?


#4

It seems to be Julia-Pro. I imagine it might be some julia-pro installation path/setting thing but I’m not 100% sure.


#5

Yes, it is Julia-Pro. I just went to julialang.org and found that this was just the recommended IDE for Julia.

Yes, this one is quite precise. However, usually it appeared on my console like this:

WARNING: Method definition 
nothing
describe(AbstractArray
accuracy TR, TE: 
) in module StatsBase at C:\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\Users\carbon\AppData\Local\JuliaPro-0.5.2.1\pkgs-0.5.2.1\v0.5\StatsBase\src\scalarstats.jl:573 overwritten in module DataFrames

I have just found out that some of the lines are products of my own code and they get interleaved with messages coming from Julia. This is the thing that made me say it had been cryptic. Now I would just say there is some bug in the environment that makes warnings interleaved with lines of another output process.


#6

Yes, I tried it also in the Windows’ console. It looks like this:

C:\Users\carbon\AppData\Local\JuliaPro-0.5.2.1\Julia-0.5.2\bin>julia usingonly.jl
WARNING: Method definition describe(AbstractArray) in module StatsBase at C:\\\\
\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\Users\carbon\AppData\Local\Jul
iaPro-0.5.2.1\pkgs-0.5.2.1\v0.5\StatsBase\src\scalarstats.jl:573 overwritten in
module DataFrames at C:\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\Use
rs\carbon\AppData\Local\JuliaPro-0.5.2.1\pkgs-0.5.2.1\v0.5\DataFrames\src\abstra
ctdataframe\abstractdataframe.jl:407.

#7

Yes, this is a known problem on windows. Also seen on AppVeyor.


#8

I have just uninstalled Julia-Pro and installed Julia-command line 0.6RC2. Now there is no warning message at all, so I cannot directly say if there are superfluous backslashes or not in that case. In other cases, however, I am getting quite a lot of new warnings from standard Julia libraries about deprecated syntax and there are only single backslashes.


#9

That’s because you’re using a version of Julia which hasn’t been released yet. Not all packages have updated.


#10

To summarize:

  • The problem with multiple backslashes looks like a bug in 0.5.2, solved in 0.6RC2.
  • I need to live with the fact that error messages span into multiple lines that can get interleaved with the output of my program.
  • I need to live with the fact that version 0.6RC2 has some packages not up to date and warning messages will appear, coming from the libraries source code.
  • Inconsistent program execution between different runs remains a problem for me, but you are right that saying “that I only tried update some packages” doesn’t look like a legitimate excuse. I will come back when I have a better example.

#11

Looks like a bug in JuliaPro. You never tried the standard v0.5.2 installation, which is the current Julia release.


#12

From what I know the huge number of backslashes is a feature (aka hack) to make it possible to ship precompiled packages. If you were to install a new package any errors from there should have the proper amount of backslashes (maybe the same is true for Pkg.update()ing and then trying again).