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

[new release] git, git-mirage, git-paf and git-unix (3.7.0) #20304

Merged
merged 8 commits into from
Dec 24, 2021

Conversation

dinosaure
Copy link
Contributor

Git format and protocol in pure OCaml

CHANGES:

CHANGES:

- Drop unneeded `mirage-protocols` dependency (@hannesm, mirage/ocaml-git#537)
- Delete HTTP functor and use happy-eyeballs (@dinosaure, mirage/ocaml-git#539)
- Be compatible with `mirage-protocols.7.0.0` (@dinosaure, mirage/ocaml-git#541)
- Use `Lwt.pause` instead of `Lwt_unix.yield` (@dinosaure, mirage/ocaml-git#542)
- Link with logs and `logs.fmt` (@MisterDA, mirage/ocaml-git#544)
@mseri
Copy link
Member

mseri commented Dec 23, 2021

There is a missing lower bound:

#=== ERROR while compiling git-unix.3.7.0 =====================================#
# context              2.1.2 | linux/x86_64 | ocaml-base-compiler.4.08.1 | pinned(https://github.com/mirage/ocaml-git/releases/download/3.7.0/git-3.7.0.tbz)
# path                 ~/.opam/4.08/.opam-switch/build/git-unix.3.7.0
# command              ~/.opam/opam-init/hooks/sandbox.sh build dune build -p git-unix -j 31
# exit-code            1
# env-file             ~/.opam/log/git-unix-17488-09f05d.env
# output-file          ~/.opam/log/git-unix-17488-09f05d.out
### output ###
# File "/home/opam/.opam/4.08/lib/io-page-unix/io-page-unix.dune", line 1, characters 0-0:
# Warning: .dune files are ignored since 2.0. Reinstall the library with dune
# >= 2.0 to get rid of this warning and enable support for the subsystem this
# library provides.
# File "/home/opam/.opam/4.08/lib/io-page/io-page.dune", line 1, characters 0-0:
# Warning: .dune files are ignored since 2.0. Reinstall the library with dune
# >= 2.0 to get rid of this warning and enable support for the subsystem this
# library provides.
#       ocamlc src/git-unix/.git_unix.objs/byte/git_unix__Git_unix_mimic.{cmi,cmo,cmt} (exit 2)
# (cd _build/default && /home/opam/.opam/4.08/bin/ocamlc.opt -w -40 -g -bin-annot -I src/git-unix/.git_unix.objs/byte -I /home/opam/.opam/4.08/lib/astring -I /home/opam/.opam/4.08/lib/bigarray-compat -I /home/opam/.opam/4.08/lib/bigstringaf -I /home/opam/.opam/4.08/lib/bos -I /home/opam/.opam/4.08/lib/ca-certs-nss -I /home/opam/.opam/4.08/lib/carton -I /home/opam/.opam/4.08/lib/cstruct -I /home/opam/.opam/4.08/lib/decompress/de -I /home/opam/.opam/4.08/lib/digestif -I /home/opam/.opam/4.08/lib/domain-name -I /home/opam/.opam/4.08/lib/fmt -I /home/opam/.opam/4.08/lib/fpath -I /home/opam/.opam/4.08/lib/git -I /home/opam/.opam/4.08/lib/git-mirage/http -I /home/opam/.opam/4.08/lib/git-mirage/ssh -I /home/opam/.opam/4.08/lib/git-mirage/tcp -I /home/opam/.opam/4.08/lib/git/nss/git -I /home/opam/.opam/4.08/lib/git/nss/smart -I /home/opam/.opam/4.08/lib/happy-eyeballs-lwt -I /home/opam/.opam/4.08/lib/ipaddr -I /home/opam/.opam/4.08/lib/ipaddr/unix -I /home/opam/.opam/4.08/lib/logs -I /home/opam/.opam/4.08/lib/lwt -I /home/opam/.opam/4.08/lib/lwt/unix -I /home/opam/.opam/4.08/lib/mimic -I /home/opam/.opam/4.08/lib/mirage-clock -I /home/opam/.opam/4.08/lib/mirage-clock-unix -I /home/opam/.opam/4.08/lib/mirage-flow -I /home/opam/.opam/4.08/lib/mirage-time -I /home/opam/.opam/4.08/lib/mirage-unix -I /home/opam/.opam/4.08/lib/mmap -I /home/opam/.opam/4.08/lib/ptime -I /home/opam/.opam/4.08/lib/ptime/os -I /home/opam/.opam/4.08/lib/result -I /home/opam/.opam/4.08/lib/rresult -I /home/opam/.opam/4.08/lib/tcpip -I /home/opam/.opam/4.08/lib/tls -I /home/opam/.opam/4.08/lib/tls-mirage -no-alias-deps -open Git_unix__ -o src/git-unix/.git_unix.objs/byte/git_unix__Git_unix_mimic.cmo -c -impl src/git-unix/git_unix_mimic.ml)
# File "src/git-unix/git_unix_mimic.ml", line 149, characters 32-38:
# 149 | module B = Git_mirage_ssh.Make (Mclock) (TCP) (Happy_eyeballs)
#                                       ^^^^^^
# Error: Unbound module Mclock

- File "/home/opam/.opam/4.08/lib/io-page-unix/io-page-unix.dune", line 1, characters 0-0:
- Warning: .dune files are ignored since 2.0. Reinstall the library with dune
- >= 2.0 to get rid of this warning and enable support for the subsystem this
- library provides.
- File "/home/opam/.opam/4.08/lib/io-page/io-page.dune", line 1, characters 0-0:
- Warning: .dune files are ignored since 2.0. Reinstall the library with dune
- >= 2.0 to get rid of this warning and enable support for the subsystem this
- library provides.
-       ocamlc src/git-unix/.git_unix.objs/byte/git_unix__Git_unix_mimic.{cmi,cmo,cmt} (exit 2)
- (cd _build/default && /home/opam/.opam/4.08/bin/ocamlc.opt -w -40 -g -bin-annot -I src/git-unix/.git_unix.objs/byte -I /home/opam/.opam/4.08/lib/astring -I /home/opam/.opam/4.08/lib/bigarray-compat -I /home/opam/.opam/4.08/lib/bigstringaf -I /home/opam/.opam/4.08/lib/bos -I /home/opam/.opam/4.08/lib/ca-certs-nss -I /home/opam/.opam/4.08/lib/carton -I /home/opam/.opam/4.08/lib/cstruct -I /home/opam/.opam/4.08/lib/decompress/de -I /home/opam/.opam/4.08/lib/digestif -I /home/opam/.opam/4.08/lib/domain-name -I /home/opam/.opam/4.08/lib/fmt -I /home/opam/.opam/4.08/lib/fpath -I /home/opam/.opam/4.08/lib/git -I /home/opam/.opam/4.08/lib/git-mirage/http -I /home/opam/.opam/4.08/lib/git-mirage/ssh -I /home/opam/.opam/4.08/lib/git-mirage/tcp -I /home/opam/.opam/4.08/lib/git/nss/git -I /home/opam/.opam/4.08/lib/git/nss/smart -I /home/opam/.opam/4.08/lib/happy-eyeballs-lwt -I /home/opam/.opam/4.08/lib/ipaddr -I /home/opam/.opam/4.08/lib/ipaddr/unix -I /home/opam/.opam/4.08/lib/logs -I /home/opam/.opam/4.08/lib/lwt -I /home/opam/.opam/4.08/lib/lwt/unix -I /home/opam/.opam/4.08/lib/mimic -I /home/opam/.opam/4.08/lib/mirage-clock -I /home/opam/.opam/4.08/lib/mirage-clock-unix -I /home/opam/.opam/4.08/lib/mirage-flow -I /home/opam/.opam/4.08/lib/mirage-time -I /home/opam/.opam/4.08/lib/mirage-unix -I /home/opam/.opam/4.08/lib/mmap -I /home/opam/.opam/4.08/lib/ptime -I /home/opam/.opam/4.08/lib/ptime/os -I /home/opam/.opam/4.08/lib/result -I /home/opam/.opam/4.08/lib/rresult -I /home/opam/.opam/4.08/lib/tcpip -I /home/opam/.opam/4.08/lib/tls -I /home/opam/.opam/4.08/lib/tls-mirage -no-alias-deps -open Git_unix__ -o src/git-unix/.git_unix.objs/byte/git_unix__Git_unix_mimic.cmo -c -impl src/git-unix/git_unix_mimic.ml)
- File "src/git-unix/git_unix_mimic.ml", line 149, characters 32-38:
- 149 | module B = Git_mirage_ssh.Make (Mclock) (TCP) (Happy_eyeballs)
-                                       ^^^^^^
- Error: Unbound module Mclock

Otherwise looks good

@dinosaure
Copy link
Contributor Author

The error on MacOS is unrelated and it's more about ca-certs (/cc @hannesm):

# +  fetch: internal error, uncaught exception:
# +         (Invalid_argument
# +            "failed to load trust anchors: ca-certs: empty trust anchors.\
# +           \nPlease report an issue at https://github.com/mirage/ca-certs, including:\
# +           \n- the output of uname -s\
# +           \n- the distribution you use\
# +           \n- the location of default trust anchors (if known)\
# +           \n")
# +         Raised at Stdlib.invalid_arg in file "stdlib.ml", line 30, characters 20-45
# +         Called from Dns_client_lwt.Transport.create in file "lwt/client/dns_client_lwt.ml", line 113, characters 28-78
# +         Called from Dns_client.Make.create in file "client/dns_client.ml", line 206, characters 18-62
# +         Called from Happy_eyeballs_lwt.create in file "lwt/happy_eyeballs_lwt.ml", line 120, characters 70-94
# +         Called from Dune__exe__Fetch.main.(fun) in file "bin/guit/fetch.ml", line 78, characters 23-51
# +         Called from Lwt.Sequential_composition.bind.create_result_promise_and_callback_if_deferred.callback in file "src/core/lwt.ml", line 1860, characters 23-26
# +         Re-raised at Lwt.Miscellaneous.poll in file "src/core/lwt.ml", line 3068, characters 20-29
# +         Called from Lwt_main.run.run_loop in file "src/unix/lwt_main.ml", line 31, characters 10-20
# +         Called from Lwt_main.run in file "src/unix/lwt_main.ml", line 118, characters 8-13
# +         Re-raised at Lwt_main.run in file "src/unix/lwt_main.ml", line 124, characters 4-13
# +         Called from Dune__exe__Fetch.main in file "bin/guit/fetch.ml", line 144, characters 8-65
# +         Called from Cmdliner_term.app.(fun) in file "cmdliner_term.ml", line 25, characters 19-24
# +         Called from Cmdliner.Term.ret.(fun) in file "cmdliner.ml", line 26, characters 27-34
# +         Called from Cmdliner.Term.run in file "cmdliner.ml", line 117, characters 32-39

@kit-ty-kate
Copy link
Member

This comes from a bug in macOS’s /usr/bin/security. There is a workaround in the opam sandbox but it’s still unclear how bad is this workaround: ocaml/opam#4797

@mseri
Copy link
Member

mseri commented Dec 24, 2021

Centos 7 and the corresponding oraclelinux have a failing test:

# [EXEC:998][bos]: ['git' 'fsck']
# warning in tree 573be7cd43eec8177dd8751310bff469963c0bfe: contains full pathnames
# warning in tree 70af2f26d50e9c2b435630042ab3bab33755b248: contains full pathnames
# error in commit dafd2874518863cf13d6ef9ad228baadcfde8a07: unterminated header
# dangling tag ce01adc8c6a86d3c19f2dab619e77c1bd525c69d
# dangling tree 990a585f623a8a827ad52706d0b9a4456aad7a0c
# dangling tag 28dadedd248da93860a3a64a67be54d6714ea0e5
# dangling commit e9507fc6116a2bd41f9275a3f9375cc7d1664449
# dangling tree 70af2f26d50e9c2b435630042ab3bab33755b248
# dangling commit f482b987902deb34b6ac3d96f236db6fa1621a5b
# dangling blob 7dd541d90a144b6231fdb508d7e5b5d41b6939d1
# ASSERT store: run ['git' 'fsck']: exited with 1
# FAIL store: run ['git' 'fsck']: exited with 1
# Raised at Alcotest_engine__Test.check_err in file "src/alcotest-engine/test.ml", line 157, characters 20-48
# Called from Alcotest_engine__Core.Make.protect_test.(fun) in file "src/alcotest-engine/core.ml", line 180, characters 17-23
# Called from Alcotest_engine__Monad.Identity.catch in file "src/alcotest-engine/monad.ml", line 24, characters 31-35
# 
# Logs saved to `~/.opam/4.13/.opam-switch/build/git-unix.3.7.0/_build/default/test/unix/_build/_tests/git-unix/write.005.output'.

Is that expected?

Besides that, it looks good to merge

@mseri
Copy link
Member

mseri commented Dec 24, 2021

Just seen the new commit, great!

@mseri
Copy link
Member

mseri commented Dec 24, 2021

Two lower bound tests (https://opam.ci.ocaml.org/github/ocaml/opam-repository/commit/bd6b0f0b24dd0a3cd9681fb3eb1d04c643f42336/variant/opam-2.1,compilers,4.11,cca.0.2,lower-bounds, https://opam.ci.ocaml.org/github/ocaml/opam-repository/commit/bd6b0f0b24dd0a3cd9681fb3eb1d04c643f42336/variant/opam-2.1,compilers,4.12,cca.0.4,lower-bounds) are failing with:


#=== ERROR while compiling git-unix.3.3.0 =====================================#
# context              2.1.2 | linux/x86_64 | ocaml-base-compiler.4.11.2 | file:///home/opam/opam-repository
# path                 ~/.opam/4.11/.opam-switch/build/git-unix.3.3.0
# command              ~/.opam/opam-init/hooks/sandbox.sh build dune build -p git-unix -j 31
# exit-code            1
# env-file             ~/.opam/log/git-unix-21-7ac27d.env
# output-file          ~/.opam/log/git-unix-21-7ac27d.out
### output ###
# File "/home/opam/.opam/4.11/lib/mirage-profile/mirage-profile.dune", line 1, characters 0-0:
# Warning: .dune files are ignored since 2.0. Reinstall the library with dune
# >= 2.0 to get rid of this warning and enable support for the subsystem this
# library provides.
#       ocamlc src/git-unix/ogit-fetch/.main.eobjs/byte/dune__exe__Main.{cmi,cmo,cmt} (exit 2)
# (cd _build/default && /home/opam/.opam/4.11/bin/ocamlc.opt -w -40 -g -bin-annot -I src/git-unix/ogit-fetch/.main.eobjs/byte -I /home/opam/.opam/4.11/lib/awa -I /home/opam/.opam/4.11/lib/awa-mirage -I /home/opam/.opam/4.11/lib/cmdliner -I /home/opam/.opam/4.11/lib/cohttp-lwt-unix -I /home/opam/.opam/4.11/lib/domain-name -I /home/opam/.opam/4.11/lib/fmt -I /home/opam/.opam/4.11/lib/fpath -I /home/opam/.opam/4.11/lib/git -I /home/opam/.opam/4.11/lib/git-cohttp-unix -I /home/opam/.opam/4.11/lib/git/nss/git -I /home/opam/.opam/4.11/lib/ipaddr -I /home/opam/.opam/4.11/lib/ipaddr/unix -I /home/opam/.opam/4.11/lib/logs -I /home/opam/.opam/4.11/lib/lwt -I /home/opam/.opam/4.11/lib/lwt/unix -I /home/opam/.opam/4.11/lib/mimic -I /home/opam/.opam/4.11/lib/mirage-clock -I /home/opam/.opam/4.11/lib/mirage-clock-unix -I /home/opam/.opam/4.11/lib/mirage-flow -I /home/opam/.opam/4.11/lib/mtime -I /home/opam/.opam/4.11/lib/mtime/os -I /home/opam/.opam/4.11/lib/result -I /home/opam/.opam/4.11/lib/rresult -I /home/opam/.opam/4.11/lib/tcpip/stack-socket -I src/git-unix/.git_unix.objs/byte -I src/git-unix/.git_unix.objs/native -no-alias-deps -o src/git-unix/ogit-fetch/.main.eobjs/byte/dune__exe__Main.cmo -c -impl src/git-unix/ogit-fetch/main.ml)
# File "src/git-unix/ogit-fetch/main.ml", line 98, characters 57-63:
# 98 |   include Awa_mirage.Make (Tcpip_stack_socket.V4V6.TCP) (Mclock)
#                                                               ^^^^^^
# Error: Unbound module Mclock
#     ocamlopt src/git-top/.git_top.objs/native/git_top.{cmx,o}
# File "_none_", line 1:
# Warning 58: no cmx file was found in path for module Toploop, and its interface was not compiled with -opaque

What is the lower bound that needs to be added to git-unix 3.3, mirage-clock 4 like above?

@mseri
Copy link
Member

mseri commented Dec 24, 2021

Looks good now, thanks

@mseri mseri merged commit 4197e15 into ocaml:master Dec 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants