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

Pkg.update broken #231

Open
essenciary opened this issue Jan 10, 2017 · 10 comments
Open

Pkg.update broken #231

essenciary opened this issue Jan 10, 2017 · 10 comments

Comments

@essenciary
Copy link

@staticfloat

Hi, I'm not sure if this is the right place to report the problem - if not, please point me in the right direction, happy to forward it.

When running Pkg.update I suddenly get:

julia> Pkg.update()
INFO: Updating METADATA...
------ PkgError ------------------------ Stacktrace (most recent call last)

 [1] — update() at pkg.jl:210

 [2] — #cd#1(::Array{Any,1}, ::Function, ::Function, ::String, ::Vararg{Any,N}) at dir.jl:31

 [3] — cd(::Base.Pkg.Dir.##2#3{Array{Any,1},Base.Pkg.Entry.#update,Tuple{String,Set{String}}}, ::String) at sys.dylib:?

 [4] — cd(::Base.Pkg.Dir.##2#3{Array{Any,1},Base.Pkg.Entry.#update,Tuple{String,Set{String}}}, ::String) at file.jl:59

 [5] — (::Base.Pkg.Dir.##2#3{Array{Any,1},Base.Pkg.Entry.#update,Tuple{String,Set{String}}})() at dir.jl:31

 [6] — update(::String, ::Set{String}) at entry.jl:354

 [7] — with(::Base.Pkg.Entry.##35#41, ::Base.LibGit2.GitRepo) at types.jl:638

 [8] — (::Base.Pkg.Entry.##35#41)(::Base.LibGit2.GitRepo) at entry.jl:378

METADATA cannot be updated. Resolve problems manually in /Users/adrian/.julia/v0.5/METADATA.
GitError(Code:ERROR, Class:Invalid, Invalid version 0 on git_proxy_options)
 in macro expansion at error.jl:99 [inlined]
 in #fetch#52(::Base.LibGit2.FetchOptions, ::String, ::Function, ::Base.LibGit2.GitRemote, ::Array{AbstractString,1}) at remote.jl:70
 in (::Base.LibGit2.#kw##fetch)(::Array{Any,1}, ::Base.LibGit2.#fetch, ::Base.LibGit2.GitRemote, ::Array{AbstractString,1}) at <missing>:0
 in #fetch#93(::String, ::String, ::Array{AbstractString,1}, ::Nullable{Base.LibGit2.AbstractCredentials}, ::Function, ::Base.LibGit2.GitRepo) at libgit2.jl:164
 in (::Base.Pkg.Entry.##35#41)(::Base.LibGit2.GitRepo) at entry.jl:371
 in with(::Base.Pkg.Entry.##35#41, ::Base.LibGit2.GitRepo) at types.jl:638
 in update(::String, ::Set{String}) at entry.jl:354
 in (::Base.Pkg.Dir.##2#3{Array{Any,1},Base.Pkg.Entry.#update,Tuple{String,Set{String}}})() at dir.jl:31
 in cd(::Base.Pkg.Dir.##2#3{Array{Any,1},Base.Pkg.Entry.#update,Tuple{String,Set{String}}}, ::String) at file.jl:59
 in cd(::Base.Pkg.Dir.##2#3{Array{Any,1},Base.Pkg.Entry.#update,Tuple{String,Set{String}}}, ::String) at sys.dylib:?
 in #cd#1(::Array{Any,1}, ::Function, ::Function, ::String, ::Vararg{Any,N}) at dir.jl:31
 in update() at pkg.jl:210
 in eval(::Module, ::Any) at boot.jl:234
 in eval(::Module, ::Any) at sys.dylib:?
 in eval_user_input(::Any, ::Base.REPL.REPLBackend) at REPL.jl:64
 in macro expansion at REPL.jl:95 [inlined]
 in (::Base.REPL.##3#4{Base.REPL.REPLBackend})() at event.jl:68

My mac got updated today (running 10.12.2 (16C67) now)

julia> versioninfo()
Julia Version 0.5.0
Commit 3c9d753* (2016-09-19 18:14 UTC)
Platform Info:
  System: Darwin (x86_64-apple-darwin15.6.0)
  CPU: Intel(R) Core(TM) i7-3740QM CPU @ 2.70GHz
  WORD_SIZE: 64
  BLAS: libopenblas (DYNAMIC_ARCH NO_AFFINITY Sandybridge)
  LAPACK: libopenblas
  LIBM: libopenlibm
  LLVM: libLLVM-3.7.1 (ORCJIT, ivybridge)

Please advise.

Thanks!

@staticfloat
Copy link
Owner

Hey @essenciary, this might need to move over to https://github.com/JuliaLang/julia, but we'll try to fix it here first. :P

First things first, upgrading your OS version often necessitates reinstalling your software; so the first thing I would try is to remove your julia and reinstall it:

$ brew rm -f $(brew deps julia) julia; brew install staticfloat/julia/julia

@tkosaka1976
Copy link

tkosaka1976 commented Jan 12, 2017

Probably, the problem come from libgit2 installed by brew upgraded to 0.24 to 0.25.
If you still have 0.24 in brew, you can switch to it.
In my case, the problem was resolved.
If you already cleanup the old version of libgit2 in brew, I updated the file in my dropbox repository (https://www.dropbox.com/s/gx870pz2alf8lv1/0.24.5.zip?dl=0).
You can copy it to your /usr/local/Cellar/libgit2/ folder.
If someone know the real link these files in homebrew repository, please tell me.

@natj
Copy link

natj commented Jan 12, 2017

Thanks @tkosaka1976 !

Can confirm that it is the recent libgit2 upgrade. For now, copying the 0.24.5/ folder to the Cellar and running brew switch libgit2 0.24.5 fixed the issue.

@essenciary
Copy link
Author

@staticfloat Thanks

That hadn't gone smoothly:

 adrian@MacBook-Pro  ~  brew rm -f $(brew deps julia) julia
Error: Refusing to uninstall /usr/local/Cellar/libffi/3.0.13
because it is required by gtk+3 3.22.6, harfbuzz 1.4.1, which are currently installed.
You can override this and force removal with:
  brew uninstall --ignore-dependencies fftw gcc gmp libffi libgit2 libssh2 mbedtls mpfr openssl pcre2 staticfloat/julia/arpack-julia staticfloat/julia/llvm37-julia staticfloat/julia/openblas-julia staticfloat/julia/suite-sparse-julia julia
 ✘ adrian@MacBook-Pro  ~  brew uninstall --ignore-dependencies fftw gcc gmp libffi libgit2 libssh2 mbedtls mpfr openssl pcre2 staticfloat/julia/arpack-julia staticfloat/julia/llvm37-julia staticfloat/julia/openblas-julia staticfloat/julia/suite-sparse-julia julia
Uninstalling /usr/local/Cellar/fftw/3.3.5... (45 files, 10.9M)
Uninstalling /usr/local/Cellar/gcc/6.3.0_1... (1,436 files, 273.2M)
Uninstalling /usr/local/Cellar/gmp/6.1.2... (18 files, 3.1M)
gmp 6.1.0, 6.1.1 are still installed.
Remove all versions with `brew uninstall --force gmp`.
Uninstalling /usr/local/Cellar/libffi/3.0.13... (15 files, 361.8K)
Uninstalling /usr/local/Cellar/libgit2/0.25.1... (105 files, 1.8M)
Uninstalling /usr/local/Cellar/libssh2/1.8.0... (182 files, 799.0K)
Uninstalling /usr/local/Cellar/mbedtls/2.4.0... (127 files, 2.8M)
Uninstalling /usr/local/Cellar/mpfr/3.1.5... (25 files, 3.6M)
mpfr 3.1.4 is still installed.
Remove all versions with `brew uninstall --force mpfr`.
Uninstalling /usr/local/Cellar/openssl/1.0.2j... (1,695 files, 12M)
openssl 1.0.2h, 1.0.2h_1 are still installed.
Remove all versions with `brew uninstall --force openssl`.
Uninstalling /usr/local/Cellar/pcre2/10.22... (199 files, 5.0M)
Uninstalling /usr/local/Cellar/arpack-julia/3.3.0_4... (9 files, 1.3M)
Uninstalling /usr/local/Cellar/llvm37-julia/3.7.1_3... (1,633 files, 200.2M)
Uninstalling /usr/local/Cellar/openblas-julia/0.2.19... (17 files, 148.6M)
openblas-julia 0.2.17, 0.2.18 are still installed.
Remove all versions with `brew uninstall --force openblas-julia`.
Uninstalling /usr/local/Cellar/suite-sparse-julia/4.4.6_2... (93 files, 3.3M)
Uninstalling /usr/local/Cellar/julia/0.5.0... (753 files, 143.2M)
 adrian@MacBook-Pro  ~  brew uninstall --force gmp
Error: Refusing to uninstall /usr/local/Cellar/gmp/6.1.1
because it is required by io, which is currently installed.
You can override this and force removal with:
  brew uninstall --ignore-dependencies gmp
 ✘ adrian@MacBook-Pro  ~  brew uninstall --ignore-dependencies gmp
Error: gmp has multiple installed versions
Use `brew uninstall --force gmp` to remove all versions.
 ✘ adrian@MacBook-Pro  ~  brew uninstall --force gmp
Error: Refusing to uninstall /usr/local/Cellar/gmp/6.1.1
because it is required by io, which is currently installed.
You can override this and force removal with:
  brew uninstall --ignore-dependencies gmp
 ✘ adrian@MacBook-Pro  ~  brew uninstall --ignore-dependencies gmp
Error: gmp has multiple installed versions
Use `brew uninstall --force gmp` to remove all versions.

Reinstalling Julia at this point still causes the same error.

@staticfloat
Copy link
Owner

Well that's annoying. You can try brew uninstall --force --ignore-dependencies gmp, e.g. pass both flags at once.

@essenciary
Copy link
Author

@tkosaka1976 Thanks, your finding was correct. Thanks for sharing the file.
@natj The brew switch did the trick :)
@staticfloat Problem solved per the above - had to manually downgrade libgit2 to 0.24.5. I hope this helps tracing the problem. Probably the issue should be kept open until having a proper fix (smooth brew upgrade path).

@tkelman
Copy link
Collaborator

tkelman commented Mar 3, 2017

The releases here should probably be deprecated in favor of using homebrew-cask with the dmg installer, unless all of the Julia dependencies that come from upstream homebrew can be pinned to versioned dependencies that are guaranteed to not have breaking upgrades.

@tcfuji
Copy link

tcfuji commented Mar 5, 2017

@tkelman If homebrew-cask dmg installation is the preferred method, it would be great if we could still have julia available on the command line to execute files. I use iTerm and the version 5.0 dmg relies on the native terminal which is less than ideal.

@tkelman
Copy link
Collaborator

tkelman commented Mar 5, 2017

does homebrew-cask add a symlink?

@tcfuji
Copy link

tcfuji commented Mar 5, 2017

I believe that is the case.

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

6 participants