Skip to content

Commit 32fa6e3

Browse files
author
Andrei Bratu
committed
typing issues
1 parent 196fc39 commit 32fa6e3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/humanloop/overload.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -264,21 +264,21 @@ def overload_client(
264264
def log_wrapper(self: T, **kwargs) -> LogResponseType:
265265
return _overload_log(self, file_syncer, use_local_files, **kwargs)
266266

267-
client.log = types.MethodType(log_wrapper, client)
267+
client.log = types.MethodType(log_wrapper, client) # type: ignore [method-assign, union-attr]
268268

269269
# Overload call method for Prompt and Agent clients
270270
if _get_file_type_from_client(client) in FileSyncer.SERIALIZABLE_FILE_TYPES:
271271
if file_syncer is None and use_local_files:
272272
logger.error("file_syncer is None but client has call method and use_local_files=%s", use_local_files)
273273
raise HumanloopRuntimeError("file_syncer is required for clients that support call operations")
274274
if hasattr(client, "call") and not hasattr(client, "_call"):
275-
client._call = client.call
275+
client._call = client.call # type: ignore [method-assign, union-attr]
276276

277277
# Create a closure to capture file_syncer and use_local_files
278278
def call_wrapper(self: T, **kwargs) -> CallResponseType:
279279
return _overload_call(self, file_syncer, use_local_files, **kwargs)
280280

281281
# Replace the call method with type ignore
282-
client.call = types.MethodType(call_wrapper, client)
282+
client.call = types.MethodType(call_wrapper, client) # type: ignore [method-assign]
283283

284284
return client

0 commit comments

Comments
 (0)