Get the mutation history for a memory.
(&self, py: Python<'_>, memory_id: String)
| 216 | |
| 217 | /// Get the mutation history for a memory. |
| 218 | fn history(&self, py: Python<'_>, memory_id: String) -> PyResult<Vec<PyMemoryHistory>> { |
| 219 | let id = parse_memory_id(&memory_id)?; |
| 220 | let service = Arc::clone(&self.service); |
| 221 | let rt = get_runtime(); |
| 222 | |
| 223 | py.allow_threads(|| { |
| 224 | rt.block_on(async move { |
| 225 | let entries = service |
| 226 | .history(&id) |
| 227 | .await |
| 228 | .map_err(to_py_runtime_error)?; |
| 229 | Ok(entries.into_iter().map(PyMemoryHistory::from).collect()) |
| 230 | }) |
| 231 | }) |
| 232 | } |
| 233 | } |
| 234 | |
| 235 | // --------------------------------------------------------------------------- |
nothing calls this directly
no test coverage detected