Skip to content

Commit

Permalink
check isinteractive at runtime
Browse files Browse the repository at this point in the history
  • Loading branch information
IanButterworth committed Apr 9, 2023
1 parent ab4863f commit 295898c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion base/loading.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1799,7 +1799,7 @@ function _require(pkg::PkgId, env=nothing)

if JLOptions().use_compiled_modules != 0
if (0 == ccall(:jl_generating_output, Cint, ())) || (JLOptions().incremental != 0)
if !pkg_precompile_attempted && isassigned(PKG_PRECOMPILE_HOOK)
if !pkg_precompile_attempted && isinteractive() && isassigned(PKG_PRECOMPILE_HOOK)
pkg_precompile_attempted = true
unlock(require_lock)
try
Expand Down

0 comments on commit 295898c

Please sign in to comment.