{"record":{"id":"71f3abe4bcb8752b","repo":"tinyhumansai/openhuman","slug":"missing-required-object-argument-filter","errorCode":null,"errorMessage":"missing required object argument `filter`","messagePattern":"missing required object argument `filter`","errorType":"validation","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"src/openhuman/integrations/task_sources/tools.rs","lineNumber":55,"sourceCode":"\nfn opt_str(args: &serde_json::Value, key: &str) -> Option<String> {\n    args.get(key)\n        .and_then(serde_json::Value::as_str)\n        .map(str::trim)\n        .filter(|s| !s.is_empty())\n        .map(str::to_string)\n}\n\nfn parse_provider(args: &serde_json::Value) -> anyhow::Result<ProviderSlug> {\n    let raw = read_required_str(args, \"provider\")?;\n    ProviderSlug::parse(&raw).map_err(|e| anyhow::anyhow!(\"invalid provider: {e}\"))\n}\n\nfn parse_filter(args: &serde_json::Value) -> anyhow::Result<FilterSpec> {\n    let val = args\n        .get(\"filter\")\n        .cloned()\n        .ok_or_else(|| anyhow::anyhow!(\"missing required object argument `filter`\"))?;\n    serde_json::from_value(val).map_err(|e| anyhow::anyhow!(\"invalid filter: {e}\"))\n}\n\nmacro_rules! emit {\n    ($outcome:expr, $name:literal) => {{\n        let outcome = $outcome.map_err(|e| anyhow::anyhow!(concat!($name, \": {}\"), e))?;\n        Ok(ToolResult::success(serde_json::to_string(&outcome.value)?))\n    }};\n}\n\n/// List configured external task sources.\npub struct TaskSourceListTool {\n    config: Arc<Config>,\n}\n\nimpl TaskSourceListTool {\n    pub fn new(config: Arc<Config>) -> Self {\n        Self { config }","sourceCodeStart":37,"sourceCodeEnd":73,"githubUrl":"https://github.com/tinyhumansai/openhuman/blob/749120085864ce16e0f273c7b86fac7740b39c5b/src/openhuman/integrations/task_sources/tools.rs#L37-L73","documentation":"parse_filter guard: the required 'filter' argument is missing entirely from the tool args, so there is no FilterSpec to deserialize. (A present-but-malformed filter produces the separate 'invalid filter' error.)","triggerScenarios":"Thrown at src/openhuman/integrations/task_sources/tools.rs:55 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Include a 'filter' object matching the FilterSpec schema in the tool call","Copy the filter shape from the tool's JSON schema description"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"749120085864ce16e0f273c7b86fac7740b39c5b","analyzedAt":"2026-08-17T21:21:45.363Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}