JuliaLang / Pkg.jl

Pkg - Package manager for the Julia programming language
https://pkgdocs.julialang.org
Other
609 stars 251 forks source link

Incorrect error message for old Manifest format #3866

Closed bluesmoon closed 2 months ago

bluesmoon commented 2 months ago
  1. The output of versioninfo()

    julia> versioninfo()
    Julia Version 1.10.2
    Commit bd47eca2c8a (2024-03-01 10:14 UTC)
    Build Info:
    Official https://julialang.org/ release
    Platform Info:
    OS: Linux (x86_64-linux-gnu)
    CPU: 12 × Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz
    WORD_SIZE: 64
    LIBM: libopenlibm
    LLVM: libLLVM-15.0.7 (ORCJIT, skylake)
    Threads: 1 default, 0 interactive, 1 GC (on 12 virtual cores)
    Environment:
    JULIA_GPG = 3673DF529D9049477F76B37566E3C7DC03D6E495
    JULIA_VERSION = 1.10.2
    JULIA_PKG_PRECOMPILE_AUTO = 0
    JULIA_PATH = /usr/local/julia
  2. How you installed Julia

Using julia docker image julia:1-bookworm

  1. A minimal working example (MWE), also known as a minimum reproducible example

I see this message with one of my packages (the package has an empty Manifest):

┌ Warning: The active manifest file at `XYZ/Manifest.toml` has an old format that is being maintained.
│ To update to the new format, which is supported by Julia versions ≥ 1.6.2, run `import Pkg; Pkg.upgrade_manifest()` which will upgrade the format without re-resolving.
│ To then record the julia version re-resolve with `Pkg.resolve()` and if there are resolve conflicts consider `Pkg.update()`.
└ @ Pkg.Types /usr/local/julia/share/julia/stdlib/v1.10/Pkg/src/manifest.jl:318

However the recommendation is incorrect. upgrade_manifest does not exist on Julia 1.6.*. It was added in 1.7.

Please fix this warning to refer to the correct version of Julia.

KristofferC commented 2 months ago

It doesn't say that upgrade_manifest exists on Julia 1.6, it says that the new manifest format is supported by Julia 1.6.2+.

bluesmoon commented 2 months ago

Not sure that's very useful because there is no way for Julia 1.6.x to actually use a v2.0 manifest.

Julia 1.6 cannot create a v2.0 manifest. The first version that can create it is 1.7, therefore the version of julia in the manifest will never be lower than 1.7, therefore julia 1.6 can never use a v2.0 manifest even if it can read it.

IanButterworth commented 2 months ago

It can maintain a v2.0 manifest, it was just decided that the time that it doesn't make sense for 1.6.2 to be able to create a new type of manifest when 1.6.1 and below couldn't.

It was more of a case of making 1.6 work rather than feature complete.

Also, note that 1.10 is likely to become an LTS soon/when 1.11 comes out. I really recommend not worrying about 1.6 anymore, unless you have a strict policy reason to.