From 21e799ae6141d8c1749a063215deeea4ca0e6209 Mon Sep 17 00:00:00 2001 From: Simon Cruanes Date: Sun, 8 Feb 2026 07:03:43 +0000 Subject: [PATCH] Fix ezcurl 0.3 compatibility issue The ezcurl library changed its client type from Curl.t to Ezcurl_core.t (an unboxed record type) in version 0.3. Updated both sync and lwt implementations to use the correct type and module functions. --- src/client-ocurl-lwt/opentelemetry_client_ocurl_lwt.ml | 6 +++--- src/client-ocurl/opentelemetry_client_ocurl.ml | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/client-ocurl-lwt/opentelemetry_client_ocurl_lwt.ml b/src/client-ocurl-lwt/opentelemetry_client_ocurl_lwt.ml index 5bc2fe7a..131d45a3 100644 --- a/src/client-ocurl-lwt/opentelemetry_client_ocurl_lwt.ml +++ b/src/client-ocurl-lwt/opentelemetry_client_ocurl_lwt.ml @@ -23,11 +23,11 @@ module Httpc : Generic_http_consumer.HTTPC with module IO = IO = struct module IO = IO open Lwt.Syntax - type t = Curl.t + type t = Ezcurl_core.t - let create () : t = Ezcurl_core.make () + let create () : t = Ezcurl_lwt.make () - let cleanup self = Ezcurl_core.delete self + let cleanup self = Ezcurl_lwt.delete self (** send the content to the remote endpoint/path *) let send (self : t) ~url ~decode (bod : string) : ('a, error) result Lwt.t = diff --git a/src/client-ocurl/opentelemetry_client_ocurl.ml b/src/client-ocurl/opentelemetry_client_ocurl.ml index 1216666d..f24d0e84 100644 --- a/src/client-ocurl/opentelemetry_client_ocurl.ml +++ b/src/client-ocurl/opentelemetry_client_ocurl.ml @@ -24,7 +24,7 @@ end module Httpc : OTELC.Generic_http_consumer.HTTPC with module IO = IO = struct module IO = IO - type t = Curl.t + type t = Ezcurl_core.t let create () = Ezcurl.make ()