Skip to content

Conversation

@KristofferC
Copy link
Member

@KristofferC KristofferC commented Oct 7, 2020

This tries to improve on the gripe here: #37904 (comment).

Instead of executing everything in the REPL process, we only execute those parts that are used to precompile specific REPL things (like tab completion, showing error messages etc). The rest is executed in a normal process which will throw if an error is produced (which turns #37904 into a hard error instead of a silent one):

ERROR: LoadError: Cannot locate '(Julia)Artifacts.toml' file when attempting to use artifact 'name' in 'Main'
Stacktrace:
 [1] error(s::String)
   @ Base ./error.jl:33
 [2] @artifact_str(__source__::LineNumberNode, __module__::Module, name::Any, platform::Any)
   @ Artifacts ~/julia/usr/share/julia/stdlib/v1.6/Artifacts/src/Artifacts.jl:590
 [3] @artifact_str(__source__::LineNumberNode, __module__::Module, name::Any)
   @ Artifacts ~/julia/usr/share/julia/stdlib/v1.6/Artifacts/src/Artifacts.jl:584
in expression starting at none:10
ERROR: LoadError: failed process: Process(`/home/kc/julia/usr/bin/julia -O0 --sysimage /home/kc/julia/usr/lib/julia/sys.ji --startup-file=no -Cnative -e '# Used by JuliaInterpreter
push!(Set{Module}(), Main)
---

Note that the offending line in #37904 is commented out because even with the change suggested in there, it fails.

@KristofferC KristofferC force-pushed the kc/better_precompile branch 3 times, most recently from daa0100 to ce24e7d Compare October 7, 2020 07:04
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.

3 participants