future-xy commited on
Commit
3237d78
1 Parent(s): 0944e42

add debug log

Browse files
Files changed (1) hide show
  1. src/utils.py +2 -1
src/utils.py CHANGED
@@ -7,7 +7,8 @@ def my_snapshot_download(repo_id, revision, local_dir, repo_type, max_workers):
7
  try:
8
  snapshot_download(repo_id=repo_id, revision=revision, local_dir=local_dir, repo_type=repo_type, max_workers=max_workers)
9
  return
10
- except Exception:
 
11
  import time
12
  time.sleep(60)
13
  return
 
7
  try:
8
  snapshot_download(repo_id=repo_id, revision=revision, local_dir=local_dir, repo_type=repo_type, max_workers=max_workers)
9
  return
10
+ except Exception as e:
11
+ print(f"Failed to download {repo_id} at {revision} with error: {e}. Retrying...")
12
  import time
13
  time.sleep(60)
14
  return