[Misc] Tiny: Add test network timeouts and dynamic max-parallel for 5090/2-gpu runners (#21800)

This commit is contained in:
Liangsheng Yin
2026-03-31 18:27:39 -07:00
committed by GitHub
parent 1389962f06
commit e4c565f2f2
4 changed files with 32 additions and 18 deletions
+1 -1
View File
@@ -516,7 +516,7 @@ def make_report_from_example_htmls(htmls: List[str]):
def download_dataset(path, url):
print(f"Downloading dataset {path} from {url}")
try:
response = requests.get(url, stream=True)
response = requests.get(url, stream=True, timeout=120)
response.raise_for_status()
total_size = int(response.headers.get("content-length", 0))
+1 -1
View File
@@ -115,7 +115,7 @@ def score_mgsm(target: str, prediction: str) -> bool:
def get_lang_examples(lang: str) -> list[dict[str, str]]:
fpath = LANG_TO_FPATH[lang]
examples = []
with urllib.request.urlopen(fpath) as f:
with urllib.request.urlopen(fpath, timeout=30) as f:
for line in f.read().decode("utf-8").splitlines():
inputs, targets = line.strip().split("\t")
if "." in targets:
+1 -1
View File
@@ -77,7 +77,7 @@ class TestOpenAIMLLMServerBase(CustomTestCase):
os.makedirs(cache_dir, exist_ok=True)
if not os.path.exists(file_path):
response = requests.get(url)
response = requests.get(url, timeout=30)
response.raise_for_status()
with open(file_path, "wb") as f: