{"record":{"id":"3d524089d94caa29","repo":"tinyhumansai/openhuman","slug":"field-must-be-a-string-or-string","errorCode":null,"errorMessage":"'{field}' must be a string or string[]","messagePattern":"'(.+?)' must be a string or string\\[\\]","errorType":"validation","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"src/openhuman/tools/impl/system/proxy_config.rs","lineNumber":88,"sourceCode":"                .map(ToOwned::to_owned)\n                .collect());\n        }\n\n        if let Some(array) = raw.as_array() {\n            let mut out = Vec::new();\n            for item in array {\n                let value = item\n                    .as_str()\n                    .ok_or_else(|| anyhow::anyhow!(\"'{field}' array must only contain strings\"))?;\n                let trimmed = value.trim();\n                if !trimmed.is_empty() {\n                    out.push(trimmed.to_string());\n                }\n            }\n            return Ok(out);\n        }\n\n        anyhow::bail!(\"'{field}' must be a string or string[]\")\n    }\n\n    fn parse_optional_string_update(args: &Value, field: &str) -> anyhow::Result<MaybeSet<String>> {\n        let Some(raw) = args.get(field) else {\n            return Ok(MaybeSet::Unset);\n        };\n\n        if raw.is_null() {\n            return Ok(MaybeSet::Null);\n        }\n\n        let value = raw\n            .as_str()\n            .ok_or_else(|| anyhow::anyhow!(\"'{field}' must be a string or null\"))?\n            .trim()\n            .to_string();\n\n        let output = if value.is_empty() {","sourceCodeStart":70,"sourceCodeEnd":106,"githubUrl":"https://github.com/tinyhumansai/openhuman/blob/749120085864ce16e0f273c7b86fac7740b39c5b/src/openhuman/tools/impl/system/proxy_config.rs#L70-L106","documentation":"parse_string_list only accepts a JSON string or an array of strings for the named field; the raw value was neither (e.g. a number, object, boolean, or an array containing non-strings after rejecting that case separately), so the proxy setting cannot be interpreted.","triggerScenarios":"Thrown at src/openhuman/tools/impl/system/proxy_config.rs:88 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Pass the field as a single string or as an array of strings","Ensure JSON numbers/booleans are quoted if they are meant as string values"],"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"}