[object Object]

← back to Exo

increase file download timeout to 30min

4748bb7dc74657a4a71d6c5f4edd51f3c538e63a · 2025-01-27 05:49:17 +0000 · Alex Cheema

Files touched

Diff

commit 4748bb7dc74657a4a71d6c5f4edd51f3c538e63a
Author: Alex Cheema <alexcheema123@gmail.com>
Date:   Mon Jan 27 05:49:17 2025 +0000

    increase file download timeout to 30min
---
 exo/download/new_shard_download.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/exo/download/new_shard_download.py b/exo/download/new_shard_download.py
index cfc22d38..2093cbcc 100644
--- a/exo/download/new_shard_download.py
+++ b/exo/download/new_shard_download.py
@@ -109,7 +109,7 @@ def calculate_repo_progress(shard: Shard, repo_id: str, revision: str, file_prog
 
 async def get_weight_map(repo_id: str, revision: str = "main") -> Dict[str, str]:
   target_dir = await ensure_exo_tmp()/repo_id.replace("/", "--")
-  async with aiohttp.ClientSession(timeout=aiohttp.ClientTimeout(total=900, connect=10, sock_read=900, sock_connect=10)) as session:
+  async with aiohttp.ClientSession(timeout=aiohttp.ClientTimeout(total=1800, connect=10, sock_read=1800, sock_connect=10)) as session:
     index_file = await download_file(session, repo_id, revision, "model.safetensors.index.json", target_dir)
     async with aiofiles.open(index_file, 'r') as f: index_data = json.loads(await f.read())
     return index_data.get("weight_map")

← ae770db4 increase download chunks to 1MB  ·  back to Exo  ·  set timeout on get too 265586f7 →