J.B-Lin commited on
Commit
e770d07
·
1 Parent(s): d67ae6b

test_omni: add stderr capture on startup failure

Browse files
Files changed (1) hide show
  1. modal_deploy/deploy_omni.py +11 -0
modal_deploy/deploy_omni.py CHANGED
@@ -925,6 +925,17 @@ def test_omni():
925
 
926
  if not ready:
927
  print(f"[FAIL] llama-server not ready after {time.time()-start:.0f}s")
 
 
 
 
 
 
 
 
 
 
 
928
  ls_proc.terminate()
929
  return
930
 
 
925
 
926
  if not ready:
927
  print(f"[FAIL] llama-server not ready after {time.time()-start:.0f}s")
928
+ # Read stderr
929
+ import select
930
+ stderr_lines = []
931
+ for _ in range(50):
932
+ line = ls_proc.stderr.readline()
933
+ if not line:
934
+ break
935
+ stderr_lines.append(line.rstrip())
936
+ print(f"[llama-server stderr] ({len(stderr_lines)} lines):")
937
+ for line in stderr_lines[-30:]:
938
+ print(f" {line}")
939
  ls_proc.terminate()
940
  return
941