-
Notifications
You must be signed in to change notification settings - Fork 143
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor: disable julia startup file for julia package update #983
refactor: disable julia startup file for julia package update #983
Conversation
Hi, thanks for the PR! I would like to know if it would affect the update in other cases by not loading this |
Sorry for accidentally closing the PR. 😵💫 |
It's difficult to answer that - there are almost certainly cases where people have unusual configuration in that file without which their Julia interpreter wouldn't work, but I'd confidently guess that the using-breakage case is much more common since that's a basic function of the feature. If any breakage is a concern, perhaps it could be gated behind a configuration flag? |
Thanks for the explanation!
Yeah, adding a configuration entry for this makes sense: [julia]
# If true, Topgrade will pass the `--startup-file=yes` option to Julia when updating it.
#
# <!!!Here, please add the use case where this option would be helpful!!!>
# startup_file = false We need a new |
38fd63a
to
75cce22
Compare
I've set the flag to default to |
Emm, what does the fixed case look like? You mean the change presented in this commit? I am not a user of Julia, but based on our discussion, making it configurable and don't change the current behavior is generally preferred, just in case. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just one nit:)
Co-authored-by: SteveLauC <stevelauc@outlook.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
What does this PR do
This PR adds the
--startup-file=no
argument to thejulia
invocation for updating Julia packages. See the upstream doc.This is useful because if Julia has been recently updated (eg. with the
juliaup
step), then old versions of packages configured withusing
directives in~/.julia/config/startup.jl
may fail to precompile or load with the new version, in turn causing the package update step to fail unnecessarily. By skipping the startup file load, broken or outdated packages will not attempt to be loaded.Standards checklist
CONTRIBUTING.md
[ ] If this PR introduces new user-facing messages they are translated