@@ -828,6 +828,7 @@ async def _batch_add_requests_worker(
828828 self ,
829829 queue : asyncio .Queue [Iterable [dict ]],
830830 request_params : dict ,
831+ timeout : Timeout ,
831832 ) -> BatchAddResponse :
832833 """Worker function to process a batch of requests.
833834
@@ -852,7 +853,7 @@ async def _batch_add_requests_worker(
852853 method = 'POST' ,
853854 params = request_params ,
854855 json = list (request_batch ),
855- timeout = 'medium' ,
856+ timeout = timeout ,
856857 )
857858
858859 result = response_to_dict (response )
@@ -879,7 +880,7 @@ async def batch_add_requests(
879880 max_parallel : int = 5 ,
880881 max_unprocessed_requests_retries : int | None = None ,
881882 min_delay_between_unprocessed_requests_retries : timedelta | None = None ,
882- timeout : Timeout = 'medium' , # noqa: ARG002
883+ timeout : Timeout = 'medium' ,
883884 ) -> BatchAddResult :
884885 """Add requests to the request queue in batches.
885886
@@ -926,7 +927,7 @@ async def batch_add_requests(
926927 async with asyncio .TaskGroup () as tg :
927928 workers = [
928929 tg .create_task (
929- self ._batch_add_requests_worker (asyncio_queue , request_params ),
930+ self ._batch_add_requests_worker (asyncio_queue , request_params , timeout ),
930931 name = f'batch_add_requests_worker_{ i } ' ,
931932 )
932933 for i in range (max_parallel )
0 commit comments