Julia: Bug: compatibility with http-parser 2.9.3 and libgit2 0.99.0-2

Created on 8 Mar 2020  ·  5Comments  ·  Source: JuliaLang/julia

I'm running julia-latest from on arch linux and I recently updated libgit2 from version 0.28.3 to 0.99.0-2 but now every time I attempt to install or update packages, the package REPL throws

ERROR: failed to clone from https://github.com/JuliaRegistries/General.git, error: GitError(Code:ERROR, Class:Invalid
, invalid version 0 on git_proxy_options)

before this error was ocurring, julia was causing a segfault attempting to install or update packages, the stack trace looked like this:

julia> Pkg.add("LightGraphs")                                                                                        
   Cloning default registries into `~/.julia`                                                                        
   Cloning registry from "https://github.com/JuliaRegistries/General.git"                                            

signal (11): Segmentation fault                                                                                      
in expression starting at REPL[2]:1                                                                                  
unknown function (ip: 0x7fef95650e73)                                                                                
http_parser_execute at /usr/bin/../lib/libhttp_parser.so.2.9 (unknown line)                                          
unknown function (ip: 0x7fef95652390)                                                                                
unknown function (ip: 0x7fef95654770)                                                                                
unknown function (ip: 0x7fef95656b58)                                                                                
unknown function (ip: 0x7fef95654f91)                                                                                
git_remote_fetch at /usr/bin/../lib/libgit2.so (unknown line)                                                        
git_clone at /usr/bin/../lib/libgit2.so (unknown line)                                                               
unknown function (ip: 0x7fefabec297f)                                                                                
unknown function (ip: 0x7fefabec3991)                                                                                
unknown function (ip: 0x7fefabef7e5e)                                                                                
unknown function (ip: 0x7fefabef83b9)                                                                                
unknown function (ip: 0x7fefabef853e)                                                                                
unknown function (ip: 0x7fefabef8dda)                                                                                
unknown function (ip: 0x7fefabefab39)                                                                                
unknown function (ip: 0x7fefabefb9b1)                                                                                
unknown function (ip: 0x7fefabf05164)                                                                                
unknown function (ip: 0x7fefabf6e9e1)                                                                                
unknown function (ip: 0x7fefabf6ec1a)                                                                                
unknown function (ip: 0x7fefabee8aeb)                                                                                
unknown function (ip: 0x7fefabee8c41)                                                                                
unknown function (ip: 0x7fefac06c12e)                                                                                
unknown function (ip: 0x7fefb8634ced)                                                                                
unknown function (ip: 0x7fefb863499a)                                                                                
unknown function (ip: 0x7fefb86356d4)                                                                                
unknown function (ip: 0x7fefb8635df9)                                                                                
unknown function (ip: 0xfffffffffffffffe)                                                                            
unknown function (ip: 0x7fefaa398e8f)                                                                                
unknown function (ip: (nil))                                                                                         
unknown function (ip: 0x7fefb8636219)                                                                                
unknown function (ip: 0x7fefb84fa4fd)                                                                                
unknown function (ip: 0x7fefb84fab88)
jl_toplevel_eval_in at /usr/bin/../lib/libjulia.so.1 (unknown line)
unknown function (ip: 0x7fefabdc3c64)
unknown function (ip: 0x7fefabfb1659)
unknown function (ip: 0x7fefabfb1954)
unknown function (ip: 0x7fefb84e0c94)
unknown function (ip: 0xffffffffffffffff)
Allocations: 2452 (Pool: 2442; Big: 10); GC: 0
fish: “julia” terminated by signal SIGSEGV (Address boundary error)

My julia version info is

julia> versioninfo()
Julia Version 1.3.1
Commit 2d5741174c (2019-12-30 21:36 UTC)
Platform Info:
  OS: Linux (x86_64-pc-linux-gnu)
  CPU: Intel(R) Xeon(R) CPU E5-1650 0 @ 3.20GHz
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-6.0.1 (ORCJIT, sandybridge)

To reproduce, install libgit2 0.99.0-2 and http-parse 2.9.3 and attempt to install or update any package.

Most helpful comment

Is there any workaround/fix for this short of downgrading libgit2 until Julia ships with a newer version?

I believe the problem is that it is not using the libgit2 that is shipped with Julia, but instead built against system libgit2. The issue is tracked here: https://bugs.archlinux.org/task/65540?string=julia&project=5&type%5B0%5D=&sev%5B0%5D=&pri%5B0%5D=&due%5B0%5D=&reported%5B0%5D=&cat%5B0%5D=&status%5B0%5D=open&percent%5B0%5D=&opened=&dev=&closed=&duedatefrom=&duedateto=&changedfrom=&changedto=&openedfrom=&openedto=&closedfrom=&closedto=

All 5 comments

We only support the versions that Julia ships with. Good to have this issue though.

Is there any workaround/fix for this short of downgrading libgit2 until Julia ships with a newer version?

Is there any workaround/fix for this short of downgrading libgit2 until Julia ships with a newer version?

I believe the problem is that it is not using the libgit2 that is shipped with Julia, but instead built against system libgit2. The issue is tracked here: https://bugs.archlinux.org/task/65540?string=julia&project=5&type%5B0%5D=&sev%5B0%5D=&pri%5B0%5D=&due%5B0%5D=&reported%5B0%5D=&cat%5B0%5D=&status%5B0%5D=open&percent%5B0%5D=&opened=&dev=&closed=&duedatefrom=&duedateto=&changedfrom=&changedto=&openedfrom=&openedto=&closedfrom=&closedto=

Suggested fix for LibGit2 0.99.0: #35232.

For those who end up here after google'ing the error: Downgrading libgit2 (1:0.99.0-3 => 1:0.28.4-1) seems to be a hacky band-aid quick fix.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

wilburtownsend picture wilburtownsend  ·  3Comments

yurivish picture yurivish  ·  3Comments

omus picture omus  ·  3Comments

i-apellaniz picture i-apellaniz  ·  3Comments

iamed2 picture iamed2  ·  3Comments