TuringLang / docs

Documentation and tutorials for the Turing language
https://turinglang.org/docs/tutorials/docs-00-getting-started/
MIT License
225 stars 97 forks source link

Error with 'DelimitedFiles.jl' when attempting to Launch "12_gaussian-process.jmd" #391

Closed patrickm663 closed 1 year ago

patrickm663 commented 1 year ago

Hi

Thank you for the great tutorials. I have learnt a lot by working through them on the website and find they are well-written.

I am attempting to launch the tutorial locally (Julia 1.9.0) using the instructions provided:

using TuringTutorials
TuringTutorials.weave("12-gaussian-process", "12_gaussian-process.jmd")

however, I end up with the following errors linked to the DelimitedFiles package it seems:

[ Info: Weaving /home/patrickmoehrke/.julia/packages/TuringTutorials/LbXCl/tutorials/12-gaussian-process/12_gaussian-process.jmd
┌ Info: Instantiating
└   folder = "12-gaussian-process"
  Activating project at `~/.julia/packages/TuringTutorials/LbXCl/tutorials/12-gaussian-process`
┌ Warning: The active manifest file is an older format with no julia version entry. Dependencies may have been resolved with a different julia version.
└ @ ~/.julia/packages/TuringTutorials/LbXCl/tutorials/12-gaussian-process/Manifest.toml:0
   Installed Tricks ────────────── v0.1.6
   Installed RecursiveArrayTools ─ v2.38.0
   Installed ReverseDiff ───────── v1.14.4
   Installed FillArrays ────────── v0.13.10
   Installed SciMLBase ─────────── v1.91.3
   Installed KernelFunctions ───── v0.10.52
   Installed AbstractGPs ───────── v0.5.14
Precompiling project...
  ✗ Plots
  33 dependencies successfully precompiled in 37 seconds. 222 already precompiled.
  1 dependency errored. To see a full report either run `import Pkg; Pkg.precompile()` or load the package
  5 dependencies had warnings during precompilation:
┌ ReverseDiff [37e2e3b7-166d-5795-8a7a-e32c996b4267]
│  ┌ Warning: Module SpecialFunctions with build ID fafbfcfd-36a6-c549-0000-009ac602fce9 is missing from the cache.
│  │ This may mean SpecialFunctions [276daf66-3868-5448-9aa4-cd146d93841b] does not support precompilation but is imported by a module that does.
│  └ @ Base loading.jl:1758
└  
┌ ColorSchemes [35d6a980-a343-548e-a6ea-1d62b119f2f4]
│  ┌ Warning: The call to compilecache failed to create a usable precompiled cache file for ColorVectorSpace [c3611d14-8923-5661-9e6a-0046d554d3a4]
│  │   exception = Required dependency SpecialFunctions [276daf66-3868-5448-9aa4-cd146d93841b] failed to load from a cache file.
│  └ @ Base loading.jl:1783
└  
┌ SciMLOperators [c0aeaf25-5076-4817-a8d5-81caf7dfa961]
│  ┌ Warning: Replacing docs for `SciMLOperators.AbstractSciMLOperator :: Union{}` in module `SciMLOperators`
│  └ @ Base.Docs docs/Docs.jl:243
└  
┌ Tracker [9f7883ad-71c0-57eb-9f7f-b5c9e6d3789c]
│  ┌ Warning: The call to compilecache failed to create a usable precompiled cache file for ForwardDiff [f6369f11-7733-5829-9624-2563aa707210]
│  │   exception = Required dependency SpecialFunctions [276daf66-3868-5448-9aa4-cd146d93841b] failed to load from a cache file.
│  └ @ Base loading.jl:1783
└  
┌ HypergeometricFunctions [34004b35-14d8-5ef3-9330-4cdb6864b03a]
│  ┌ Warning: The call to compilecache failed to create a usable precompiled cache file for DualNumbers [fa6b7ba4-c1ee-5f82-b5fc-ecf0adba8f74]
│  │   exception = Required dependency SpecialFunctions [276daf66-3868-5448-9aa4-cd146d93841b] failed to load from a cache file.
│  └ @ Base loading.jl:1783
└  
ERROR: Could not find either `git-tree-sha1` or `path` for package DelimitedFiles
Stacktrace:
  [1] pkgerror(msg::String)
    @ Pkg.Types ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/Types.jl:69
  [2] build_versions(ctx::Pkg.Types.Context, uuids::Set{Base.UUID}; verbose::Bool)
    @ Pkg.Operations ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/Operations.jl:1069
  [3] build_versions
    @ ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/Operations.jl:1049 [inlined]
  [4] build(ctx::Pkg.Types.Context, uuids::Set{Base.UUID}, verbose::Bool)
    @ Pkg.Operations ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/Operations.jl:991
  [5] build(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}; verbose::Bool, kwargs::Base.Pairs{Symbol, Base.TTY, Tuple{Symbol}, NamedTuple{(:io,), Tuple{Base.TTY}}})
    @ Pkg.API ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/API.jl:1053
  [6] build(pkgs::Vector{Pkg.Types.PackageSpec}; io::Base.TTY, kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ Pkg.API ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/API.jl:156
  [7] build(pkgs::Vector{Pkg.Types.PackageSpec})
    @ Pkg.API ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/API.jl:145
  [8] build(; name::Nothing, uuid::Nothing, version::Nothing, url::Nothing, rev::Nothing, path::Nothing, mode::Pkg.Types.PackageMode, subdir::Nothing, kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ Pkg.API ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/API.jl:171
  [9] build
    @ ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/API.jl:162 [inlined]
 [10] weave(folder::String, file::String; out_path_root::String, build::Tuple{Symbol, Symbol, Symbol})
    @ TuringTutorials ~/.julia/packages/TuringTutorials/LbXCl/src/TuringTutorials.jl:47
 [11] weave(folder::String, file::String)
    @ TuringTutorials ~/.julia/packages/TuringTutorials/LbXCl/src/TuringTutorials.jl:23
 [12] top-level scope
    @ REPL[5]:1

Re-running the above produces a new set of errors linked to the DelimitedFiles package:

[ Info: Weaving /home/patrickmoehrke/.julia/packages/TuringTutorials/LbXCl/tutorials/12-gaussian-process/12_gaussian-process.jmd
┌ Info: Instantiating
└   folder = "12-gaussian-process"
  Activating project at `~/.julia/packages/TuringTutorials/LbXCl/tutorials/12-gaussian-process`
ERROR: Could not locate the source code for the DelimitedFiles package. Are you trying to use a manifest generated by a different version of Julia?
Stacktrace:
  [1] pkgerror(msg::String)
    @ Pkg.Types ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/Types.jl:69
  [2] is_package_downloaded(project_file::String, pkg::Pkg.Types.PackageSpec; platform::Base.BinaryPlatforms.Platform)
    @ Pkg.Operations ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/Operations.jl:2186
  [3] is_package_downloaded
    @ ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/Operations.jl:2183 [inlined]
  [4] #10
    @ ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/Operations.jl:133 [inlined]
  [5] _all
    @ ./reduce.jl:1283 [inlined]
  [6] #all#830
    @ ./reducedim.jl:1007 [inlined]
  [7] all
    @ ./reducedim.jl:1007 [inlined]
  [8] is_instantiated(env::Pkg.Types.EnvCache; platform::Base.BinaryPlatforms.Platform)
    @ Pkg.Operations ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/Operations.jl:133
  [9] is_instantiated
    @ ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/Operations.jl:117 [inlined]
 [10] instantiate(ctx::Pkg.Types.Context; manifest::Nothing, update_registry::Bool, verbose::Bool, platform::Base.BinaryPlatforms.Platform, allow_build::Bool, allow_autoprecomp::Bool, kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ Pkg.API ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/API.jl:1687
 [11] instantiate
    @ ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/API.jl:1640 [inlined]
 [12] instantiate(; kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ Pkg.API ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/API.jl:1639
 [13] instantiate
    @ ~/.julia/juliaup/julia-1.9.0+0.x64.linux.gnu/share/julia/stdlib/v1.9/Pkg/src/API.jl:1639 [inlined]
 [14] weave(folder::String, file::String; out_path_root::String, build::Tuple{Symbol, Symbol, Symbol})
    @ TuringTutorials ~/.julia/packages/TuringTutorials/LbXCl/src/TuringTutorials.jl:46
 [15] weave(folder::String, file::String)
    @ TuringTutorials ~/.julia/packages/TuringTutorials/LbXCl/src/TuringTutorials.jl:23
 [16] top-level scope
    @ REPL[5]:1

Any help would be greatly appreciated.

Regards Patrick

devmotion commented 1 year ago

The tutorials are run with and the provided Manifest.toml files (which fix the package versions) are only valid for Julia LTS (ie 1.6). Manifest.toml files are generally not transferrable between Julia versions.

patrickm663 commented 1 year ago

Okay got it, thanks for the quick response @devmotion !