Shell: update to lwt.2.7.0
This commit is contained in:
parent
7689021810
commit
df81d95614
@ -198,7 +198,7 @@ end = struct
|
||||
|
||||
let lock = Lwt_mutex.create ()
|
||||
|
||||
let get_block cctxt level =
|
||||
let get_block _cctxt level =
|
||||
Lwt_mutex.with_lock lock
|
||||
(fun () ->
|
||||
load () >>=? fun map ->
|
||||
|
@ -93,12 +93,15 @@ let filter_valid_endorsement cctxt { hash; content } =
|
||||
let monitor_endorsement cctxt =
|
||||
monitor cctxt ~contents:true ~check:true () >>= fun ops_stream ->
|
||||
let endorsement_stream, push = Lwt_stream.create () in
|
||||
Lwt_stream.on_termination ops_stream (fun () -> push None) ;
|
||||
Lwt.async (fun () ->
|
||||
Lwt.async begin fun () ->
|
||||
Lwt_stream.closed ops_stream >|= fun () -> push None
|
||||
end;
|
||||
Lwt.async begin fun () ->
|
||||
Lwt_stream.iter_p
|
||||
(Lwt_list.iter_p (fun e ->
|
||||
filter_valid_endorsement cctxt e >>= function
|
||||
| None -> Lwt.return_unit
|
||||
| Some e -> push (Some e) ; Lwt.return_unit))
|
||||
ops_stream) ;
|
||||
ops_stream
|
||||
end ;
|
||||
Lwt.return endorsement_stream
|
||||
|
@ -15,7 +15,7 @@ let cctxt = Client_commands.ignore_context
|
||||
|
||||
let root =
|
||||
let root =
|
||||
RPC.register RPC.empty Services.contracts @@ fun block () ->
|
||||
RPC.register RPC.empty Services.contracts @@ fun _block () ->
|
||||
Client_proto_contracts.RawContractAlias.load cctxt >>= fun list ->
|
||||
let (names, _) = List.split list in
|
||||
RPC.Answer.return names in
|
||||
|
@ -18,21 +18,22 @@ depends: [
|
||||
"calendar"
|
||||
"cohttp" {>= "0.21" }
|
||||
"config-file"
|
||||
"conduit" {= "0.14.0" } # Version 0.14.1 doas not compile with `ssl` (17/01/02)
|
||||
"conduit"
|
||||
"git"
|
||||
"git-unix"
|
||||
"irmin-watcher" (* for `irmin.unix` *)
|
||||
"irmin" {>= "0.12"}
|
||||
"irmin" {>= "0.12" }
|
||||
"lwt" {>= "2.7.0" }
|
||||
"lwt_ssl"
|
||||
"menhir"
|
||||
"ocp-ocamlres" {>= "dev"}
|
||||
"ocp-ocamlres" {>= "dev" }
|
||||
"ocplib-endian"
|
||||
"ocplib-json-typed"
|
||||
"ocplib-resto" {>= "dev"}
|
||||
"ocplib-resto" {>= "dev" }
|
||||
"reactiveData"
|
||||
"tyxml"
|
||||
"js_of_ocaml"
|
||||
"sodium" {>= "0.3.0"}
|
||||
"ssl"
|
||||
"sodium" {>= "0.3.0" }
|
||||
"kaputt" # { test }
|
||||
"bisect_ppx" # { test }
|
||||
]
|
||||
|
Loading…
Reference in New Issue
Block a user