MakieOrg / Makie.jl

Interactive data visualizations and plotting in Julia
https://docs.makie.org/stable
MIT License
2.4k stars 308 forks source link

World-age issue in StableHashTraits dependency #3420

Closed kbarros closed 1 month ago

kbarros commented 10 months ago

A world-age issue appears when Julia is launched without compiled modules. Create a fresh environment including only GLMakie:

julia --compiled-modules=no
] activate --temp
add GLMakie

Trying to load GLMakie gives this error:

julia> using GLMakie
ERROR: LoadError: MethodError: no method matching cleanup_name(::String)
The applicable method may be too new: running in world age 66051, while current world is 66217.

Closest candidates are:
  cleanup_name(::Any) (method too new to be called from this world context.)
   @ StableHashTraits ~/.julia/packages/StableHashTraits/cnBjT/src/StableHashTraits.jl:530

Stacktrace:
  [1] qname_(T::Type, name::typeof(string))
    @ StableHashTraits ~/.julia/packages/StableHashTraits/cnBjT/src/StableHashTraits.jl:417
  [2] qualified_type_(x::Type{Vector{Union{Makie.ClosePath, Makie.CurveTo, Makie.EllipticalArc, Makie.LineTo, Makie.MoveTo}}})
    @ StableHashTraits ~/.julia/packages/StableHashTraits/cnBjT/src/StableHashTraits.jl:421
  [3] qualified_(T::Type, #unused#::Type{Val{:type}})
    @ StableHashTraits ~/.julia/packages/StableHashTraits/cnBjT/src/StableHashTraits.jl:427
  [4] #s3402#10

[...]

 [36] require(into::Module, mod::Symbol)
    @ Base ./loading.jl:1611
in expression starting at /Users/kbarros/.julia/packages/Makie/pCA2E/src/bezier.jl:659
in expression starting at /Users/kbarros/.julia/packages/Makie/pCA2E/src/Makie.jl:1
in expression starting at /Users/kbarros/.julia/packages/GLMakie/vf9WN/src/GLMakie.jl:1

The problem may originate in StableHashTraits, and I filed an issue there: https://github.com/beacon-biosignals/StableHashTraits.jl/issues/36. The purpose of this issue is to notify other Makie users who may encounter the same problem. In particular, this will cause a failure of JuliaHub documentation builds that rely on Makie for images.

felixcremer commented 10 months ago

I also got that when I tried to use Makie as a weak dependency see https://github.com/yeesian/ArchGDAL.jl/pull/404 with Makie 0.19. It disappeared when using Makie 0.20.

felixcremer commented 10 months ago

This issues has been closed upstream in 1.1.3. Should we increase the bound for StableHashTraits to version 1.1.3 and could we also push this bounds change to Makie 0.19?

ffreyer commented 1 month ago

We no longer depend on StableHashTraits