Skip to content
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

Launch the manifest-specified Julia version #1059

Closed
wants to merge 7 commits into from
Closed
Prev Previous commit
Next Next commit
Use correct way to show error message when launching from manifest
davidanthoff authored and tecosaur committed Oct 27, 2024

Verified

This commit was signed with the committer’s verified signature.
addaleax Anna Henningsen
commit e5c245a2337546bbc6794ed802fcad3dc2b6e1b8
4 changes: 2 additions & 2 deletions src/bin/julialauncher.rs
Original file line number Diff line number Diff line change
@@ -180,10 +180,10 @@ fn get_julia_path_from_channel(
) -> Result<(PathBuf, Vec<String>)> {
if let JuliaupChannelSource::Manifest { version } = launch_parameters {
let version_string = versions_db.available_channels.get(version)
.ok_or_else(|| anyhow!("The project you are trying to launch uses Julia {}, but no such Julia version exists. Please make sure you are using a valid Julia manifest file.", version))?;
.ok_or_else(|| UserError {msg: format!("The project you are trying to launch uses Julia {}, but no such Julia version exists. Please make sure you are using a valid Julia manifest file.", version) } )?;

let version_config = config_data.installed_versions.get(&version_string.version)
.ok_or_else(|| anyhow!("The project you are trying to launch uses Julia {}, but you do not have that version installed. You can install it by running `juliaup add {}`.", version, version))?;
.ok_or_else(|| UserError {msg: format!("The project you are trying to launch uses Julia {}, but you do not have that version installed. You can install it by running `juliaup add {}`.", version, version) } )?;

let absolute_path = juliaupconfig_path
.parent()