From 6fc6eb0c07eeaa009737e2c59ad538ff043eb6e5 Mon Sep 17 00:00:00 2001 From: Kristoffer Carlsson Date: Mon, 29 Apr 2024 15:03:43 +0200 Subject: [PATCH] ensure package callbacks are invoked when no valid precompile file exists for an "auto loaded" stdlib (#54248) The `_require` call skips the logic for running package callbacks (and extension triggers) so if Pkg is loaded in the startup file and then REPL failed to load from `_require_search_from_serialized` (and instead loaded via `_require`) the REPL extension from Pkg would not load. (cherry picked from commit 32653877719a7dc25a37227807eacd2634ebdbe4) --- base/loading.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/loading.jl b/base/loading.jl index 2e9bd1432e9a0..e7ff3abc13fb0 100644 --- a/base/loading.jl +++ b/base/loading.jl @@ -2499,7 +2499,7 @@ function require_stdlib(uuidkey::PkgId, ext::Union{Nothing, String}=nothing) run_package_callbacks(uuidkey) else # if the user deleted their bundled depot, next try to load it completely normally - newm = _require(uuidkey) + newm = _require_prelocked(uuidkey) end return newm end