Skip to content

REPL: Precompilation breaks on 1.11 if sysimage contains multiple exts with the same name #57939

@IanButterworth

Description

@IanButterworth

This will break if two different packages in the sysimage have the same named ext.

https://github.com/JuliaLang/julia/pull/49937/files#diff-b0f1c124df9a9d6599825734623e73617bf4cdc8b1fd2687b080d29b3c4183c8R7-R12

Not a problem on 1.12 because that was removed in #55210

And not a problem on 1.10 because REPL was in the sysimage back then.

$ /home/ian/.julia/juliaup/julia-1.11.4+0.x64.linux.gnu/bin/julia -t 10 -J /home/ian/foo/sysimages/custom-x86_64-julia_v1.11.4-v2.82.5.so --project=/home/ian/foo/project
Precompiling REPL...
Info Given REPL was explicitly requested, output will be shown live 
ERROR: LoadError: invalid redefinition of constant Precompile.AdaptExt
Stacktrace:
  [1] top-level scope
    @ none:1
  [2] eval
    @ ./boot.jl:430 [inlined]
  [3] eval
    @ ~/.julia/juliaup/julia-1.11.4+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/precompile.jl:3 [inlined]
  [4] top-level scope
    @ ~/.julia/juliaup/julia-1.11.4+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/precompile.jl:10
  [5] include(mod::Module, _path::String)
    @ Base ./Base.jl:557
  [6] include(x::String)
    @ REPL ~/.julia/juliaup/julia-1.11.4+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/REPL.jl:15
  [7] top-level scope
    @ ~/.julia/juliaup/julia-1.11.4+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/REPL.jl:1748
  [8] include
    @ ./Base.jl:557 [inlined]
  [9] include_package_for_output(pkg::Base.PkgId, input::String, depot_path::Vector{String}, dl_load_path::Vector{String}, load_path::Vector{String}, concrete_deps::Vector{Pair{Base.PkgId, UInt128}}, source::Nothing)
    @ Base ./loading.jl:2881
 [10] top-level scope
    @ stdin:6
in expression starting at /home/ian/.julia/juliaup/julia-1.11.4+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/precompile.jl:3
in expression starting at /home/ian/.julia/juliaup/julia-1.11.4+0.x64.linux.gnu/share/julia/stdlib/v1.11/REPL/src/REPL.jl:3
in expression starting at stdin:6

Metadata

Metadata

Assignees

No one assigned

    Labels

    REPLJulia's REPL (Read Eval Print Loop)bugIndicates an unexpected problem or unintended behaviorregression 1.11Regression in the 1.11 release

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions