{"record":{"id":"0ed00aeda9c8383a","repo":"tinyhumansai/openhuman","slug":"no-active-native-browser-session-run-browser-acti","errorCode":null,"errorMessage":"No active native browser session. Run browser action='open' first","messagePattern":"No active native browser session\\. Run browser action='open' first","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"src/openhuman/tools/impl/browser/native_backend.rs","lineNumber":379,"sourceCode":"            builder.capabilities(capabilities);\n        }\n\n        let client = builder\n            .connect(webdriver_url)\n            .await\n            .with_context(|| {\n                format!(\n                    \"Failed to connect to WebDriver at {webdriver_url}. Start chromedriver/geckodriver first\"\n                )\n            })?;\n\n        self.client = Some(client);\n        Ok(())\n    }\n\n    fn active_client(&self) -> Result<&Client> {\n        self.client.as_ref().ok_or_else(|| {\n            anyhow::anyhow!(\"No active native browser session. Run browser action='open' first\")\n        })\n    }\n}\n\nfn webdriver_endpoint_reachable(webdriver_url: &str, timeout: Duration) -> bool {\n    let parsed = match reqwest::Url::parse(webdriver_url) {\n        Ok(url) => url,\n        Err(_) => return false,\n    };\n\n    if parsed.scheme() != \"http\" && parsed.scheme() != \"https\" {\n        return false;\n    }\n\n    let host = match parsed.host_str() {\n        Some(h) if !h.is_empty() => h,\n        _ => return false,\n    };","sourceCodeStart":361,"sourceCodeEnd":397,"githubUrl":"https://github.com/tinyhumansai/openhuman/blob/749120085864ce16e0f273c7b86fac7740b39c5b/src/openhuman/tools/impl/browser/native_backend.rs#L361-L397","documentation":"Sentinel from active_client in the native backend: no WebDriver client is connected because no browser session was opened yet (or the previous session died). The session field is Option; every element-taking action routes through this accessor and fails until action='open' initialises it.","triggerScenarios":"Thrown at src/openhuman/tools/impl/browser/native_backend.rs:379 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Run browser action='open' with a url before element actions","Re-open the session if the previous one crashed or was closed"],"exampleFix":null,"handlingStrategy":"fallback","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"}