Skip to content

Commit

Permalink
Merge pull request #10244 from PumasAI/jk/fix-manifest-current
Browse files Browse the repository at this point in the history
Handle API change in `is_manifest_current` in Julia 1.11
  • Loading branch information
cscheid authored Jul 8, 2024
2 parents b7150a0 + 28fa943 commit cb8c8b7
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/resources/julia/ensure_environment.jl
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,13 @@ function manifest_has_correct_julia_version()
return version.major == VERSION.major && version.minor == VERSION.minor
end

manifest_matches_project_toml = Pkg.is_manifest_current() === true # this returns nothing if there's no manifest
is_manifest_current = @static if VERSION < v"1.11.0-DEV.1135"
Pkg.is_manifest_current()
else
Pkg.is_manifest_current(dirname(Base.active_project()))
end

manifest_matches_project_toml = is_manifest_current === true # this returns nothing if there's no manifest

if manifest_matches_project_toml && manifest_has_correct_julia_version()
Pkg.instantiate()
Expand Down

0 comments on commit cb8c8b7

Please sign in to comment.