(&self, py: Python<'py>)
| 76 | } |
| 77 | |
| 78 | pub fn recv<'py>(&self, py: Python<'py>) -> PyResult<Bound<'py, PyAny>> { |
| 79 | let inner = Arc::clone(&self.inner); |
| 80 | |
| 81 | future_into_py(py, async move { |
| 82 | let resp = inner.lock().await.recv().await; |
| 83 | |
| 84 | resp.map(|r| convert_response(r?).context("convert response")) |
| 85 | .transpose() |
| 86 | .map_err(Into::into) |
| 87 | }) |
| 88 | } |
| 89 | } |
| 90 | |
| 91 | #[pyclass] |
no test coverage detected