Function
limited_request_func
(request_func_input, pbar)
Source from the content-addressed store, hash-verified
| 372 | semaphore = asyncio.Semaphore(max_concurrency) if max_concurrency else None |
| 373 | |
| 374 | async def limited_request_func(request_func_input, pbar): |
| 375 | if semaphore is None: |
| 376 | return await request_func(request_func_input=request_func_input, pbar=pbar) |
| 377 | async with semaphore: |
| 378 | return await request_func(request_func_input=request_func_input, pbar=pbar) |
| 379 | |
| 380 | benchmark_start_time = time.perf_counter() |
| 381 | |
Tested by
no test coverage detected