mirror of
https://github.com/xtekky/gpt4free.git
synced 2026-01-06 01:02:13 -08:00
Add zerogpu_uuid to demo
This commit is contained in:
parent
be8c3f7cd2
commit
9994bb67a1
7 changed files with 37 additions and 13 deletions
|
|
@ -431,7 +431,7 @@ async def download_urls(
|
|||
connector=get_connector(proxy=proxy),
|
||||
timeout=ClientTimeout(timeout)
|
||||
) as session:
|
||||
async def download_url(url: str) -> str:
|
||||
async def download_url(url: str, max_depth: int) -> str:
|
||||
try:
|
||||
async with session.get(url) as response:
|
||||
response.raise_for_status()
|
||||
|
|
@ -457,7 +457,7 @@ async def download_urls(
|
|||
except (ClientError, asyncio.TimeoutError) as e:
|
||||
debug.log(f"Download failed: {e.__class__.__name__}: {e}")
|
||||
return None
|
||||
for filename in await asyncio.gather(*[download_url(url) for url in urls]):
|
||||
for filename in await asyncio.gather(*[download_url(url, max_depth) for url in urls]):
|
||||
if filename:
|
||||
yield filename
|
||||
else:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue