(self, request_id, timeout=START_TIMEOUT)
| 398 | raise SmokeFailure("thin client closed while sending: " + str(exc)) from exc |
| 399 | |
| 400 | def wait_response(self, request_id, timeout=START_TIMEOUT): |
| 401 | deadline = time.monotonic() + timeout |
| 402 | with self.condition: |
| 403 | while request_id not in self.responses: |
| 404 | remaining = deadline - time.monotonic() |
| 405 | if remaining <= 0 or self.stdout_closed: |
| 406 | break |
| 407 | self.condition.wait(remaining) |
| 408 | if request_id in self.responses: |
| 409 | return self.responses[request_id] |
| 410 | raise SmokeFailure( |
| 411 | "no response for request {} (exit={}, stderr={!r}, other={!r})".format( |
| 412 | request_id, |
| 413 | self.process.poll(), |
| 414 | self.stderr_text(), |
| 415 | self.other_output, |
| 416 | ) |
| 417 | ) |
| 418 | |
| 419 | def has_response(self, request_id): |
| 420 | with self.condition: |
no test coverage detected