Skip to content

Conversation

@MeganDawson42
Copy link

Update this as CoreLogging has changed.

@MeganDawson42
Copy link
Author

@c42f let me know if there's any other changes to make :)

Copy link

@andyferris andyferris left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thoughts, @c42f?

@samuel-massinon
Copy link

Bump on this.

Ran into this issue here JuliaLang/julia#59267

@MarkNahabedian
Copy link

I was going to file this as an issue, but I think it relates to this PR:

I get this error from my CI.yml, but not when running tests locally:

│   exception =
│    MethodError: no method matching isless(::Int32, ::Base.CoreLogging.LogLevel)
│    The function `isless` exists, but no method is defined for this combination of argument types.
│    
│    Closest candidates are:
│      isless(::Base.CoreLogging.LogLevel, ::Base.CoreLogging.LogLevel)
│       @ Base logging/logging.jl:131
│      isless(::Missing, ::Any)
│       @ Base missing.jl:87
│      isless(::Any, ::Missing)
│       @ Base missing.jl:88
│      ...
│    
│    Stacktrace:
│     [1] <(x::Int32, y::Base.CoreLogging.LogLevel)
│       @ Base ./operators.jl:353
│     [2] <=(x::Int32, y::Base.CoreLogging.LogLevel)
│       @ Base ./operators.jl:402
│     [3] >=(x::Base.CoreLogging.LogLevel, y::Int32)
│       @ Base ./operators.jl:426
│     [4] unsafe_write(s::Logging2.LoggingStream{Base.CoreLogging.ConsoleLogger, Base.CoreLogging.LogLevel}, p::Ptr{UInt8}, n::UInt64)
│       @ Logging2 ~/.julia/packages/Logging2/MNTyk/src/LoggingStream.jl:34
│     [5] unsafe_write(io::Logging2.LineBufferedIO{Logging2.LoggingStream{Base.CoreLogging.ConsoleLogger, Base.CoreLogging.LogLevel}}, p::Ptr{UInt8}, n::UInt64)
│       @ Logging2 ~/.julia/packages/Logging2/MNTyk/src/LineBufferedIO.jl:71
│     [6] unsafe_write
│       @ ./io.jl:803 [inlined]
│     [7] write
│       @ ./io.jl:837 [inlined]
│     [8] write(to::Logging2.LineBufferedIO{Logging2.LoggingStream{Base.CoreLogging.ConsoleLogger, Base.CoreLogging.LogLevel}}, from::Base.PipeEndpoint)
│       @ Base ./io.jl:884
│     [9] (::Base.var"#887#888"{Base.PipeEndpoint, Logging2.LineBufferedIO{Logging2.LoggingStream{Base.CoreLogging.ConsoleLogger, Base.CoreLogging.LogLevel}}, Base.PipeEndpoint})()
│       @ Base ./process.jl:313
└ @ Base process.jl:315

Base.unsafe_write in Logging2/MNTyk/src/LoggingStream.jl has

    # These tests capture the essence of the logging early-bailout in Base.CoreLogging.
    #
    # NOTE: These refer to internals of CoreLogging and will need to be kept in
    # sync if things change upstream.
    if #==# level >= Base.CoreLogging._min_enabled_level[] &&
            level >= s.logstate.min_enabled_level &&
            Logging.shouldlog(s.logger, level, _module, group, id)

The package getting this CI error is https://github.com/MarkNahabedian/WebScrapingTools.jl.

It needs to run firefox and geckodriver in the test environment,but I don't see how that could cause this error.

@MeganDawson42
Copy link
Author

@MarkNahabedian Potentially you're running an older version of Julia locally that doesn't hit this error? The CI.yml is using v 1.11 which hits this issue

@MarkNahabedian
Copy link

Sorry, I should have thought to check versions.

My local test run:

julia version 1.11.2
[18cd0bd4] Logging2 v0.1.1
[56ddb016] Logging v1.11.0

My failing CI:

Julia 1.11.7
[18cd0bd4] Logging2 v0.1.1
[56ddb016] Logging v1.11.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants