(self, timeout=None)
| 68 | self.status = self.CANCELED |
| 69 | |
| 70 | def wait(self, timeout=None): |
| 71 | start_time = time.time() |
| 72 | while True: |
| 73 | if not BACKEND_UPDATE: |
| 74 | self.agent.update() |
| 75 | if self.status == self.WAITING: |
| 76 | time.sleep(0.005) |
| 77 | if timeout and time.time() - start_time > timeout: |
| 78 | raise RpcTimeoutError(self) |
| 79 | else: |
| 80 | break |
| 81 | return self.result, self.error |
| 82 | |
| 83 | def __str__(self): |
| 84 | conn = self.agent.get_connection() |
no test coverage detected