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

KeyError: key "git-tree-sha1" not found (Windows) #191

Closed
amellnik opened this issue Mar 12, 2018 · 3 comments
Closed

KeyError: key "git-tree-sha1" not found (Windows) #191

amellnik opened this issue Mar 12, 2018 · 3 comments

Comments

@amellnik
Copy link

I'm on 00ac33a3ef (12 March), and I've seen this over the past month or so.

Init works OK:

pkg> init
[ Info: Initialized environment by creating C:\Users\amellnik\AppData\Local\Julia-0.7.0-DEV\Project.toml

But any add fails immediately:

pkg> add IJulia
[ Info: Resolving package versions
ERROR: KeyError: key "git-tree-sha1" not found
Stacktrace:
 [1] getindex(::Dict{String,Any}, ::String) at .\dict.jl:478
 [2] (::getfield(Pkg3.Operations, Symbol("##1#2")))(::Pair{String,Any}) at .\<missing>:0
 [3] next at .\generator.jl:47 [inlined]
 [4] Dict{VersionNumber,Base.SHA1}(::Base.Generator{Dict{String,Any},getfield(Pkg3.Operations, Symbol("##1#2"))}) at .\dict.jl:110
 [5] load_versions at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\site\v0.7\Pkg3\src\Operations.jl:23 [inlined]
 [6] deps_graph(::Pkg3.Types.Context, ::Dict{Base.UUID,String}, ::Dict{Base.UUID,Pkg3.Types.VersionSpec}, ::Dict{Base.UUID,Pkg3.Types.Fixed}) at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\site\v0.7\Pkg3\src\Operations.jl:183
 [7] resolve_versions!(::Pkg3.Types.Context, ::Array{Pkg3.Types.PackageSpec,1}) at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\site\v0.7\Pkg3\src\Operations.jl:252
 [8] add(::Pkg3.Types.Context, ::Array{Pkg3.Types.PackageSpec,1}) at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\site\v0.7\Pkg3\src\Operations.jl:851
 [9] #add#4(::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::Function, ::Pkg3.Types.Context, ::Array{Pkg3.Types.PackageSpec,1}) at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\site\v0.7\Pkg3\src\API.jl:29
 [10] add at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\site\v0.7\Pkg3\src\API.jl:21 [inlined]
 [11] do_add!(::Pkg3.Types.Context, ::Array{Union{Pkg3.Types.VersionRange, String, Pkg3.REPLMode.Command, Pkg3.REPLMode.Option, Pkg3.REPLMode.Rev},1}) at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\site\v0.7\Pkg3\src\REPLMode.jl:536
 [12] (::getfield(Base, Symbol("#inner#4")){Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}},typeof(Pkg3.REPLMode.do_add!),Tuple{Pkg3.Types.Context,Array{Union{Pkg3.Types.VersionRange, String, Pkg3.REPLMode.Command, Pkg3.REPLMode.Option, Pkg3.REPLMode.Rev},1}}})() at .\essentials.jl:641
 [13] #invokelatest#3 at .\essentials.jl:642 [inlined]
 [14] invokelatest at .\essentials.jl:641 [inlined]
 [15] do_cmd!(::Array{Union{Pkg3.Types.VersionRange, String, Pkg3.REPLMode.Command, Pkg3.REPLMode.Option, Pkg3.REPLMode.Rev},1}, ::REPL.LineEditREPL) at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\site\v0.7\Pkg3\src\REPLMode.jl:255
 [16] do_cmd(::REPL.LineEditREPL, ::String) at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\site\v0.7\Pkg3\src\REPLMode.jl:219
 [17] (::getfield(Pkg3.REPLMode, Symbol("##8#9")){REPL.LineEditREPL,REPL.LineEdit.Prompt})(::REPL.LineEdit.MIState, ::Base.GenericIOBuffer{Array{UInt8,1}}, ::Bool) at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\site\v0.7\Pkg3\src\REPLMode.jl:754
 [18] top-level scope
@amellnik amellnik changed the title KeyError: key "git-tree-sha1" not found on WIndows KeyError: key "git-tree-sha1" not found (Windows) Mar 12, 2018
@amellnik
Copy link
Author

Solved by Sebastian Pfitzner on Slack -- I needed to delete all non-v0.6 directories in .julia.

@KristofferC
Copy link
Sponsor Member

Can you try do an pkg> up first.

@KristofferC
Copy link
Sponsor Member

Oh. I think the problem here was an old registry.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants