Skip to content

Commit 6d80d9c

Browse files
committed
block main thread
1 parent 4f2f4a8 commit 6d80d9c

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/twinkle/server/launcher.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,9 @@
2222
"""
2323
from __future__ import annotations
2424

25-
import os
2625
import time
2726
from pathlib import Path
28-
from typing import Any, Callable, Dict, List, Optional, Union
27+
from typing import Any, Callable, Dict, Optional, Union
2928

3029
from twinkle import get_logger
3130

@@ -273,7 +272,8 @@ def launch(self, wait: bool = True) -> None:
273272
print(f" - http://{host}:{port}{route_prefix}")
274273

275274
if wait:
276-
input("\nPress Enter to stop the server...")
275+
while True:
276+
time.sleep(3600)
277277

278278
@classmethod
279279
def from_yaml(

0 commit comments

Comments
 (0)