MCPcopy Index your code
hub / github.com/AI45Lab/Code / subagent_tasks

Method subagent_tasks

sdk/python/src/lib.rs:1873–1880  ·  view source on GitHub ↗

Return snapshots of every delegated subagent task observed in this session (including completed and failed ones), oldest first.

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

Source from the content-addressed store, hash-verified

1871 /// Return snapshots of every delegated subagent task observed in this
1872 /// session (including completed and failed ones), oldest first.
1873 fn subagent_tasks(&self, py: Python<'_>) -> PyResult<PyObject> {
1874 let session = self.inner.clone();
1875 let tasks = py.allow_threads(move || get_runtime().block_on(session.subagent_tasks()));
1876 let json = serde_json::to_string(&tasks).map_err(|e| {
1877 PyRuntimeError::new_err(format!("Failed to serialize subagent tasks: {e}"))
1878 })?;
1879 json_string_to_py(py, &json)
1880 }
1881
1882 /// Return snapshots of subagent tasks still in `running` state.
1883 fn pending_subagent_tasks(&self, py: Python<'_>) -> PyResult<PyObject> {

Callers 1

mainFunction · 0.45

Calls 4

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

Tested by 1

mainFunction · 0.36