MCPcopy
hub / github.com/baidu/Unlimited-OCR / stop_server

Function stop_server

infer.py:139–148  ·  view source on GitHub ↗
(process)

Source from the content-addressed store, hash-verified

137
138
139def stop_server(process):
140 if process is None:
141 return
142 process.terminate()
143 try:
144 process.wait(timeout=30)
145 except subprocess.TimeoutExpired:
146 process.kill()
147 process.wait()
148 process._log_file.close()
149
150
151def collect_stream_silent(resp, output_file: str | None) -> dict:

Callers 2

start_serverFunction · 0.85
mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected