There was an error while loading. Please reload this page.
1 parent 5a370f0 commit 16c110cCopy full SHA for 16c110c
2 files changed
examples/foo.py
@@ -1,4 +1,5 @@
1
import time
2
+
3
print("hello world")
4
while True:
- time.sleep(1)
5
+ time.sleep(1)
examples/start_vllm.py
@@ -11,6 +11,7 @@
11
"""
12
13
import httpx
14
15
import pylet
16
17
@@ -41,7 +42,7 @@ def main():
41
42
# 3. Wait for vLLM to be ready (model loading takes time)
43
print("Waiting for vLLM to load model...")
44
with httpx.Client(timeout=300) as http:
- for attempt in range(60): # up to 5 minutes
45
+ for _attempt in range(60): # up to 5 minutes
46
try:
47
resp = http.get(f"http://{instance.endpoint}/v1/models")
48
if resp.status_code == 200:
@@ -50,6 +51,7 @@ def main():
50
51
except httpx.ConnectError:
52
pass
53
54
55
time.sleep(5)
56
else:
57
print("Timeout waiting for vLLM")
0 commit comments