Logging.jl icon indicating copy to clipboard operation
Logging.jl copied to clipboard

@Logging.configure throws error in Julia v0.6

Open VHarisop opened this issue 7 years ago • 3 comments

When trying to use the logging macros:

julia> using Logging
julia> @Logging.configure(level=INFO)
ERROR: MethodError: no method matching override_info(::Logging.LogLevel)
Closest candidates are:
    override_info(; args...) at /home/vharisop/.julia/v0.6/Logging/src/Logging.jl:143
[vharisop@alwaysbored] julia -v
julia version 0.6.3

VHarisop avatar Aug 01 '18 19:08 VHarisop

same for me on version 0.6.4

amebru avatar Aug 11 '18 20:08 amebru

By simply following the error hint, I modified the function as below which will work with Julia 0.6.4.

  • 143 #override_info(;args...) = (:override_info, true) in args
  • 144 override_info(level::LogLevel;args...) = (:override_info, true) in args

dawnsong avatar Feb 11 '19 16:02 dawnsong

I found the code in github might not be pushed to julia 0.6.4 package management. If you install Logging directly from the github, it works for 0.6.4, i.e., instead of Pkg.add("Logging"), do Pkg.clone("https://github.com/kmsquire/Logging.jl.git")

dawnsong avatar Feb 11 '19 16:02 dawnsong