diff --git a/opam-repo-ci-web.opam b/opam-repo-ci-web.opam index b06a771b..0268fcc5 100644 --- a/opam-repo-ci-web.opam +++ b/opam-repo-ci-web.opam @@ -29,7 +29,7 @@ depends: [ "prometheus-app" "cmdliner" {>= "1.1.0"} "lwt" - "cohttp-lwt-unix" {>= "2.2.0"} + "cohttp-lwt-unix" {>= "6.0.0"} "mirage-crypto-rng" {>= "0.11.0"} "tyxml" "capnp-rpc-unix" diff --git a/web-ui/github.ml b/web-ui/github.ml index 03ee51fe..609d3dc5 100644 --- a/web-ui/github.ml +++ b/web-ui/github.ml @@ -283,10 +283,9 @@ module Repo_handle = struct (* Otherwise, an nginx reverse proxy will wait for the whole log before sending anything. *) Cohttp.Header.init_with "X-Accel-Buffering" "no" in - let res = Cohttp.Response.make ~status:`OK ~flush:true ~encoding:Cohttp.Transfer.Chunked ~headers () in + let res = Cohttp.Response.make ~status:`OK ~encoding:Cohttp.Transfer.Chunked ~headers () in let write _ic oc = - let flush = Cohttp.Response.flush res in - let writer = Transfer_IO.make_writer ~flush Cohttp.Transfer.Chunked oc in + let writer = Transfer_IO.make_writer ~flush:true Cohttp.Transfer.Chunked oc in Lwt.finalize (fun () -> stream_logs job ~owner ~name ~refs ~hash ~variant ~status chunk writer >>= fun () ->