Skip to content

Test for libgit2 fails in Julia v1.2---but code works fine? #33095

@ghost

Description

Hi,

I don't know if this is a bug/issue but it's related to the ticket #33038 .

Until yesterday, in Arch linux, julia didn't use the system libgit2 library (I guess it used Julia's fork?) resulting in the problem updating packages reported in #33038 . Now, recompiling julia to make use of libgit2 installed in the system fixed that problem... however when I ran the test for libgit2 it failed (specifically, the test for use_http_path):

(v1.2) pkg> test LibGit2
  Updating registry at `/usr/applications/academia/julia/registries/General`
  Updating git-repo `https://github.com/JuliaRegistries/General.git`
   Testing LibGit2
 Resolving package versions...
    Status `/tmp/jl_XDKMIu/Manifest.toml`
  [2a0f44e3] Base64  [`@stdlib/Base64`]
  [8ba89e20] Distributed  [`@stdlib/Distributed`]
  [b77e0a4c] InteractiveUtils  [`@stdlib/InteractiveUtils`]
  [76f85450] LibGit2  [`@stdlib/LibGit2`]
  [56ddb016] Logging  [`@stdlib/Logging`]
  [d6f4376e] Markdown  [`@stdlib/Markdown`]
  [9a3f8284] Random  [`@stdlib/Random`]
  [9e88b42a] Serialization  [`@stdlib/Serialization`]
  [6462fe0b] Sockets  [`@stdlib/Sockets`]
  [8dfed614] Test  [`@stdlib/Test`]
Test Summary:         | Pass  Total
Check library version |    1      1
Test Summary:          | Pass  Total
Check library features |    2      2
Test Summary: | Pass  Total
OID           |   10     10
Test Summary:  | Pass  Total
StrArrayStruct |    1      1
Test Summary: | Pass  Total
Signature     |    5      5
Test Summary:  | Pass  Total
Default config |    4      4
Test Summary:               | Pass  Total
Default config with symlink |    2      2
Test Summary:   | Pass  Total
Git URL parsing |   42     42
Test Summary:      | Pass  Total
Git URL formatting |   11     11
Test Summary:       | Pass  Total
Passphrase Required |    6      6
Test Summary: | Pass  Total
GitCredential |   54     54
Test Summary: | Pass  Total
Configuration |   15     15
Test Summary:           | Pass  Total
Configuration Iteration |    6      6
Test Summary:           | Pass  Total
Initializing repository |   30     30
Test Summary:      | Pass  Total
Cloning repository |   19     19
Test Summary:           | Pass  Total
Update cache repository |  176    176
Test Summary:      | Pass  Total
Fastforward merges |    8      8
Test Summary: | Pass  Total
Cherrypick    |    1      1
Test Summary: | Pass  Total
Merges        |    9      9
Test Summary: | Pass  Total
push          |    2      2
Test Summary:    | Pass  Total
Show closed repo |    1      1
Test Summary:               | Pass  Total
Fetch from cache repository |   32     32
Test Summary:           | Pass  Total
Examine test repository |   11     11
Test Summary:               | Pass  Total
Modify and reset repository |   20     20
Test Summary: | Pass  Total
Modify remote |   27     27
Test Summary: | Pass  Total
rebase        |   11     11
Test Summary: | Pass  Total
merge         |    1      1
Test Summary:            | Pass  Total
Transact test repository |    5      5
Test Summary:     | Pass  Total
checkout/headname |    2      2
Test Summary:     | Pass  Total
checkout/proptest |    2      2
Test Summary: | Pass  Total
Credentials   |    8      8
Test Summary:     | Pass  Total
CachedCredentials |   23     23
Test Summary:           | Pass  Total
Git credential username |    9      9
use_http_path: Test Failed at /usr/share/julia/stdlib/v1.2/LibGit2/test/libgit2.jl:1930
  Expression: !(LibGit2.use_http_path(cfg, github_cred))
Stacktrace:
 [1] (::getfield(Main.LibGit2Tests, Symbol("##96#214")))(::LibGit2.GitConfig) at /usr/share/julia/stdlib/v1.2/LibGit2/test/libgit2.jl:1930
 [2] with(::getfield(Main.LibGit2Tests, Symbol("##96#214")), ::LibGit2.GitConfig) at /build/julia/src/julia-1.2.0/usr/share/julia/stdlib/v1.2/LibGit2/src/types.jl:1125
 [3] macro expansion at /usr/share/julia/stdlib/v1.2/LibGit2/test/libgit2.jl:1909 [inlined]
 [4] macro expansion at /build/julia/src/julia-1.2.0/usr/share/julia/stdlib/v1.2/Test/src/Test.jl:1113 [inlined]
 [5] macro expansion at /usr/share/julia/stdlib/v1.2/LibGit2/test/libgit2.jl:1906 [inlined]
 [6] macro expansion at /build/julia/src/julia-1.2.0/usr/share/julia/stdlib/v1.2/Test/src/Test.jl:1113 [inlined]
 [7] (::getfield(Main.LibGit2Tests, Symbol("##23#138")))(::String) at /usr/share/julia/stdlib/v1.2/LibGit2/test/libgit2.jl:1905
Test Summary:           | Pass  Fail  Total
Git helpers useHttpPath |    6     1      7
  use_http_path         |    6     1      7
ERROR: LoadError: LoadError: Some tests did not pass: 6 passed, 1 failed, 0 errored, 0 broken.
in expression starting at /usr/share/julia/stdlib/v1.2/LibGit2/test/libgit2.jl:596
in expression starting at /usr/share/julia/stdlib/v1.2/LibGit2/test/runtests.jl:3
ERROR: Package LibGit2 errored during testing

Julia still works as intended as far as I can tell. When I ran the same test using the official binaries it passed, but useHttpPath is reported as broken:

(v1.2) pkg> test LibGit2
  Updating registry at `/usr/applications/academia/julia/registries/General`
  Updating git-repo `https://github.com/JuliaRegistries/General.git`
   Testing LibGit2
 Resolving package versions...
    Status `/tmp/jl_ddOPw1/Manifest.toml`
  [2a0f44e3] Base64  [`@stdlib/Base64`]
  [8ba89e20] Distributed  [`@stdlib/Distributed`]
  [b77e0a4c] InteractiveUtils  [`@stdlib/InteractiveUtils`]
  [76f85450] LibGit2  [`@stdlib/LibGit2`]
  [56ddb016] Logging  [`@stdlib/Logging`]
  [d6f4376e] Markdown  [`@stdlib/Markdown`]
  [9a3f8284] Random  [`@stdlib/Random`]
  [9e88b42a] Serialization  [`@stdlib/Serialization`]
  [6462fe0b] Sockets  [`@stdlib/Sockets`]
  [8dfed614] Test  [`@stdlib/Test`]
Test Summary:         | Pass  Total
Check library version |    1      1
Test Summary:          | Pass  Total
Check library features |    2      2
Test Summary: | Pass  Total
OID           |   10     10
Test Summary:  | Pass  Total
StrArrayStruct |    1      1
Test Summary: | Pass  Total
Signature     |    5      5
Test Summary:  | Pass  Total
Default config |    4      4
Test Summary:               | Pass  Total
Default config with symlink |    2      2
Test Summary:   | Pass  Total
Git URL parsing |   42     42
Test Summary:      | Pass  Total
Git URL formatting |   11     11
Test Summary:       | Pass  Total
Passphrase Required |    6      6
Test Summary: | Pass  Total
GitCredential |   54     54
Test Summary: | Pass  Total
Configuration |   15     15
Test Summary:           | Pass  Total
Configuration Iteration |    6      6
Test Summary:           | Pass  Total
Initializing repository |   30     30
Test Summary:      | Pass  Total
Cloning repository |   19     19
Test Summary:           | Pass  Total
Update cache repository |  176    176
Test Summary:      | Pass  Total
Fastforward merges |    8      8
Test Summary: | Pass  Total
Cherrypick    |    1      1
Test Summary: | Pass  Total
Merges        |    9      9
Test Summary: | Pass  Total
push          |    2      2
Test Summary:    | Pass  Total
Show closed repo |    1      1
Test Summary:               | Pass  Total
Fetch from cache repository |   32     32
Test Summary:           | Pass  Total
Examine test repository |   11     11
Test Summary:               | Pass  Total
Modify and reset repository |   20     20
Test Summary: | Pass  Total
Modify remote |   27     27
Test Summary: | Pass  Total
rebase        |   11     11
Test Summary: | Pass  Total
merge         |    1      1
Test Summary:            | Pass  Total
Transact test repository |    5      5
Test Summary:     | Pass  Total
checkout/headname |    2      2
Test Summary:     | Pass  Total
checkout/proptest |    2      2
Test Summary: | Pass  Total
Credentials   |    8      8
Test Summary:     | Pass  Total
CachedCredentials |   23     23
Test Summary:           | Pass  Total
Git credential username |    9      9
Test Summary:           | Pass  Total
Git helpers useHttpPath |    7      7
The following 'Resetting the helper list...' warning is expected:
┌ Warning: Resetting the helper list is currently unsupported:
│ ignoring all git credential helpers
└ @ LibGit2 /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.2/LibGit2/src/gitcredential.jl:234
Test Summary:       | Pass  Broken  Total
GitCredentialHelper |   24       1     25
Test Summary:         | Pass  Total
SSH credential prompt |   43     43
Test Summary:           | Pass  Total
HTTPS credential prompt |   10     10
Test Summary:      | Pass  Total
SSH agent username |    4      4
Test Summary: | Pass  Total
SSH default   |    6      6
Test Summary:    | Pass  Total
SSH expand tilde |    6      6
Test Summary:            | Pass  Total
SSH explicit credentials |    8      8
Test Summary:              | Pass  Total
HTTPS explicit credentials |    8      8
Test Summary:      | Pass  Total
Cached credentials |   22     22
Test Summary:             | Pass  Total
HTTPS git helper username |    3      3
Test Summary:             | Pass  Total
HTTPS git helper password |    3      3
Test Summary:                     | Pass  Total
Incompatible explicit credentials |    8      8
Test Summary:              | Pass  Total
SSH & HTTPS authentication |    2      2
Test Summary:           | Pass  Total
CredentialPayload reset |    4      4
Test Summary:         | Pass  Total
Hostname verification |    5      5
Test Summary:      | Pass  Total
Cloning repository |   10     10
   Testing LibGit2 tests passed 

With the official binaries I can update the registry and Arch now fixed the problem by making Julia use the libgit2 installed in the system (up until 1.1 it was using Julia's just fine). But there's obviously an inconsistency here and I wondered if the problems with #33038 may somehow be related...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions