From ed191cdeec40b08937cc56af23a893cdb4b9484d Mon Sep 17 00:00:00 2001 From: Anders Fugmann Date: Wed, 13 Mar 2024 22:21:02 +0100 Subject: [PATCH] Remove deprecation warnings --- aws-s3-async/io.ml | 2 +- aws-s3/s3.ml | 4 ++-- cli/aws.ml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/aws-s3-async/io.ml b/aws-s3-async/io.ml index d4e7399..061ffb9 100644 --- a/aws-s3-async/io.ml +++ b/aws-s3-async/io.ml @@ -87,7 +87,7 @@ module Net = struct in let interrupt = match connect_timeout_ms with | None -> None - | Some ms -> Some (Async.after (Core.Time.Span.of_ms (float ms))) + | Some ms -> Some (Async.after (Core.Time_float.Span.of_ms (float ms))) in Async.try_with (fun () -> Conduit_async.V3.connect_uri ?interrupt ~options uri) >>=? fun (socket, ic, oc) -> let reader = Reader.pipe ic in diff --git a/aws-s3/s3.ml b/aws-s3/s3.ml index e66cd07..07b717a 100644 --- a/aws-s3/s3.ml +++ b/aws-s3/s3.ml @@ -411,7 +411,7 @@ module Make(Io : Types.Io) = struct |> Delete_multi.xml_of_request |> fun req -> Ezxmlm.to_string [ req ] in - let headers = [ "Content-MD5", Base64.encode_string (Caml.Digest.string request) ] in + let headers = [ "Content-MD5", Base64.encode_string (Stdlib.Digest.string request) ] in let headers = maybe_add_request_payer confirm_requester_pays headers in let body, sink = string_sink () in let cmd () = @@ -547,7 +547,7 @@ module Make(Io : Types.Io) = struct let query = [ "uploadId", t.id ] in let request = (* TODO: Sort the parts by partNumber *) - let parts = Caml.List.sort (fun a b -> compare a.Multipart.part_number b.part_number) t.parts in + let parts = Stdlib.List.sort (fun a b -> compare a.Multipart.part_number b.part_number) t.parts in Multipart.Complete.(xml_of_request { parts }) |> (fun node -> Format.asprintf "%a" Ezxmlm.pp [node]) in diff --git a/cli/aws.ml b/cli/aws.ml index c712a52..e288060 100644 --- a/cli/aws.ml +++ b/cli/aws.ml @@ -211,7 +211,7 @@ module Make(Io : Aws_s3.Types.Io) = struct | Some t -> Ptime.to_rfc3339 ~space:false t in let rec ls_all ?max_keys (result, cont) = - List.iter ~f:(fun { S3.last_modified; key; size; etag; _ } -> Caml.Printf.printf "%s\t%d\t%s\t%s\n%!" (string_of_time last_modified) size key etag) result; + List.iter ~f:(fun { S3.last_modified; key; size; etag; _ } -> Stdlib.Printf.printf "%s\t%d\t%s\t%s\n%!" (string_of_time last_modified) size key etag) result; let max_keys = match max_keys with | Some n -> Some (n - List.length result) | None -> None