diff --git a/multicall/call.py b/multicall/call.py index 05f76c6..c773f1f 100644 --- a/multicall/call.py +++ b/multicall/call.py @@ -92,8 +92,8 @@ def decode_output( else: decoded = [None] * (1 if not returns else len(returns)) # type: ignore - logger.debug(f"returns: {returns}") - logger.debug(f"decoded: {decoded}") + logger.debug("returns: %s", returns) + logger.debug("decoded: %s", decoded) if returns: return { diff --git a/multicall/multicall.py b/multicall/multicall.py index 50f67a5..ec2382f 100644 --- a/multicall/multicall.py +++ b/multicall/multicall.py @@ -90,7 +90,7 @@ def __init__( def __call__(self) -> Dict[str, Any]: start = time() response = await_awaitable(self) - logger.debug(f"Multicall took {time() - start}s") + logger.debug("Multicall took %ss", time() - start) return response def __await__(self) -> Dict[str, Any]: @@ -110,7 +110,7 @@ async def coroutine(self) -> Dict[str, Any]: async def fetch_outputs( self, calls: List[Call], ConnErr_retries: int = 0, id: str = "" ) -> List[CallResponse]: - logger.debug(f"coroutine {id} started") + logger.debug("coroutine %s started", id) if calls is None: calls = self.calls @@ -126,16 +126,12 @@ async def fetch_outputs( outputs = await gather( [ run_in_subprocess( - Call.decode_output, - output, - call.signature, - call.returns, - success, + Call.decode_output, output, call.signature, call.returns, success ) for call, (success, output) in zip(calls, outputs) ] ) - logger.debug(f"coroutine {id} finished") + logger.debug("coroutine %s finished", id) return outputs except Exception as e: _raise_or_proceed(e, len(calls), ConnErr_retries=ConnErr_retries) @@ -149,7 +145,7 @@ async def fetch_outputs( ) return_val = await run_in_subprocess(unpack_batch_results, batch_results) - logger.debug(f"coroutine {id} finished") + logger.debug("coroutine %s finished", id) return return_val @property