Not sure what happened here, but I'll put it here and see if I can reproduce it. In any case this could be a better error.
$ julia-master --project -e 'using Pkg; Pkg.activate("docs"); Pkg.instantiate(); Pkg.develop(PackageSpec(path = pwd()))'
[ Info: activating environment at `~/dev/Pkg/docs/Project.toml`.
Updating registry at `~/.julia/registries/General`
Updating git-repo `https://github.com/JuliaRegistries/General.git`
Updating registry at `~/.julia/registries/Staging`
Updating git-repo `https://github.com/fredrikekre/Staging.git`
ERROR: TypeError: in typeassert, expected VersionNumber, got Pkg.Types.VersionSpec
Stacktrace:
[1] load_urls(::Pkg.Types.Context, ::Array{Pkg.Types.PackageSpec,1}) at /home/fredrik/dev/Pkg/src/Operations.jl:438
[2] #download_source#66 at /home/fredrik/dev/Pkg/src/Operations.jl:562 [inlined]
[3] download_source at /home/fredrik/dev/Pkg/src/Operations.jl:561 [inlined]
[4] #instantiate#81(::Nothing, ::Bool, ::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::typeof(Pkg.API.instantiate), ::Pkg.Types.Context) at /home/fredrik/dev/Pkg/src/API.jl:479
[5] instantiate at /home/fredrik/dev/Pkg/src/API.jl:461 [inlined]
[6] #instantiate#80 at /home/fredrik/dev/Pkg/src/API.jl:458 [inlined]
[7] instantiate() at /home/fredrik/dev/Pkg/src/API.jl:458
[8] top-level scope at none:1
I can reproduce this issue using Project.toml and Manifest.toml in https://gist.github.com/tkf/1fac12181ba095cb1ec08241c1659b62 with Julia 1.2.0-DEV.614 (719c0620e4) but not with Julia 1.1. Procedure:
$ git clone https://gist.github.com/tkf/1fac12181ba095cb1ec08241c1659b62 bug
$ cd bug
$ julia --project=.
...
(bug) pkg> instantiate
Updating registry at `~/.julia/registries/General`
Updating git-repo `https://github.com/JuliaRegistries/General.git`
ERROR: TypeError: in typeassert, expected VersionNumber, got Pkg.Types.VersionSpec
Stacktrace:
[1] load_urls(::Pkg.Types.Context, ::Array{Pkg.Types.PackageSpec,1}) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/Operations.jl:438
[2] #download_source#66 at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/Operations.jl:562 [inlined]
[3] download_source at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/Operations.jl:561 [inlined]
[4] #instantiate#81(::Nothing, ::Bool, ::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::typeof(Pkg.API.instantiate), ::Pkg.Types.Context) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/API.jl:486
...
Full output
Updating registry at `~/.julia/registries/General`
Updating git-repo `https://github.com/JuliaRegistries/General.git`
ERROR: TypeError: in typeassert, expected VersionNumber, got Pkg.Types.VersionSpec
Stacktrace:
[1] load_urls(::Pkg.Types.Context, ::Array{Pkg.Types.PackageSpec,1}) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/Operations.jl:438
[2] #download_source#66 at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/Operations.jl:562 [inlined]
[3] download_source at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/Operations.jl:561 [inlined]
[4] #instantiate#81(::Nothing, ::Bool, ::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::typeof(Pkg.API.instantiate), ::Pkg.Types.Context) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/API.jl:486
[5] instantiate at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/API.jl:461 [inlined]
[6] do_instantiate!(::Dict{Symbol,Any}, ::Array{String,1}, ::Dict{Symbol,Any}) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/REPLMode.jl:468
[7] #invokelatest#1(::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::typeof(Base.invokelatest), ::Any, ::Any, ::Vararg{Any,N} where N) at ./essentials.jl:790
[8] invokelatest(::Any, ::Any, ::Vararg{Any,N} where N) at ./essentials.jl:789
[9] do_cmd!(::Pkg.REPLMode.Command, ::REPL.LineEditREPL) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/REPLMode.jl:403
[10] #do_cmd#23(::Bool, ::typeof(Pkg.REPLMode.do_cmd), ::REPL.LineEditREPL, ::String) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/REPLMode.jl:382
[11] do_cmd at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/REPLMode.jl:378 [inlined]
[12] (::getfield(Pkg.REPLMode, Symbol("##28#31")){REPL.LineEditREPL,REPL.LineEdit.Prompt})(::REPL.LineEdit.MIState, ::Base.GenericIOBuffer{Array{UInt8,1}}, ::Bool) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/Pkg/src/REPLMode.jl:610
[13] #invokelatest#1 at ./essentials.jl:790 [inlined]
[14] invokelatest at ./essentials.jl:789 [inlined]
[15] run_interface(::REPL.Terminals.TextTerminal, ::REPL.LineEdit.ModalInterface, ::REPL.LineEdit.MIState) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/REPL/src/LineEdit.jl:2306
[16] run_frontend(::REPL.LineEditREPL, ::REPL.REPLBackendRef) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/REPL/src/REPL.jl:1038
[17] run_repl(::REPL.AbstractREPL, ::Any) at /home/takafumi/repos/watch/julia/usr/share/julia/stdlib/v1.2/REPL/src/REPL.jl:201
[18] (::getfield(Base, Symbol("##732#734")){Bool,Bool,Bool,Bool})(::Module) at ./client.jl:390
[19] #invokelatest#1 at ./essentials.jl:790 [inlined]
[20] invokelatest at ./essentials.jl:789 [inlined]
[21] run_main_repl(::Bool, ::Bool, ::Bool, ::Bool, ::Bool) at ./client.jl:374
[22] exec_options(::Base.JLOptions) at ./client.jl:312
[23] _start() at ./client.jl:464
Note that Project.toml and Manifest.toml are not "compatible". They are copied from different projects. instantiate works after resolve.
closed by #1209
I see the same error on github actions using julia v.15
https://github.com/baggepinnen/SymbolicControlSystems.jl/runs/1369554854?check_suite_focus=true#step:5:13
Had the same problem on 1.5 CI here, after CompatHelper merge: https://github.com/endremborza/BigO.jl/runs/2395906695?check_suite_focus=true
ran resolve locally, pushed the new Manifest, that fixed it:
https://github.com/endremborza/BigO.jl/runs/2395990813?check_suite_focus=true