MCPcopy Create free account
hub / github.com/Paper2Poster/Paper2Poster / wait

Method wait

camel/runtime/remote_http_runtime.py:161–174  ·  view source on GitHub ↗

r"""Wait for the API Server to be ready. Args: timeout (int): The number of seconds to wait. (default: :obj: `10`) Returns: bool: Whether the API Server is ready.

(self, timeout: int = 10)

Source from the content-addressed store, hash-verified

159 return False
160
161 def wait(self, timeout: int = 10) -> bool:
162 r"""Wait for the API Server to be ready.
163
164 Args:
165 timeout (int): The number of seconds to wait. (default: :obj: `10`)
166
167 Returns:
168 bool: Whether the API Server is ready.
169 """
170 for _ in range(timeout):
171 if self.ok:
172 return True
173 time.sleep(1)
174 return False
175
176 def __del__(self):
177 r"""Clean up the API server when the object is deleted."""

Callers 1

_cleanupMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected