MCPcopy Create free account
hub / github.com/AI45Lab/Code / active_tools

Method active_tools

sdk/python/src/lib.rs:1850–1857  ·  view source on GitHub ↗

Return active tool calls observed for the currently running operation.

(&self, py: Python<'_>)

Source from the content-addressed store, hash-verified

1848
1849 /// Return active tool calls observed for the currently running operation.
1850 fn active_tools(&self, py: Python<'_>) -> PyResult<PyObject> {
1851 let session = self.inner.clone();
1852 let active_tools = py.allow_threads(move || get_runtime().block_on(session.active_tools()));
1853 let json = serde_json::to_string(&active_tools).map_err(|e| {
1854 PyRuntimeError::new_err(format!("Failed to serialize active tools: {e}"))
1855 })?;
1856 json_string_to_py(py, &json)
1857 }
1858
1859 /// Look up a delegated subagent task by id. Returns None when no such
1860 /// task has been observed in this session.

Callers

nothing calls this directly

Calls 4

json_string_to_pyFunction · 0.85
block_onMethod · 0.80
get_runtimeFunction · 0.70
cloneMethod · 0.45

Tested by

no test coverage detected