diff --git a/cli/src/native/browser.rs b/cli/src/native/browser.rs index 9bad985..de57509 100644 --- a/cli/src/native/browser.rs +++ b/cli/src/native/browser.rs @@ -1116,6 +1116,17 @@ impl BrowserManager { }; if let Some(ref error_text) = nav_result.error_text { + // `data:` URLs abort over the extension relay: chrome.debugger / + // chrome.tabs can't drive a top-frame data: navigation, so it comes + // back net::ERR_ABORTED on an about:blank tab. Explain it instead of + // leaking the cryptic code (data: works fine under `--launch`). + if url.starts_with("data:") && error_text.contains("ERR_ABORTED") { + return Err(format!( + "Navigation failed: {error_text}. Chrome blocks top-frame `data:` URLs over \ + the extension relay — use a real http(s):// or file:// URL, or run with \ + `--launch` (where data: URLs work)." + )); + } return Err(format!("Navigation failed: {}", error_text)); } diff --git a/cli/src/output.rs b/cli/src/output.rs index 50202f9..480109d 100644 --- a/cli/src/output.rs +++ b/cli/src/output.rs @@ -3577,6 +3577,9 @@ iOS Simulator (requires Xcode and Appium): chrome-use -p ios device list # List simulators chrome-use -p ios swipe up # Swipe gesture chrome-use -p ios tap @e1 # Touch element + +Hit a bug or rough edge? A 30-second issue genuinely sharpens this tool: + https://github.com/leeguooooo/chrome-use/issues "# ); } @@ -3659,6 +3662,7 @@ fn print_screenshot_diff(data: &serde_json::Map) { pub fn print_version() { println!("chrome-use {}", env!("CARGO_PKG_VERSION")); + println!("report bugs / rough edges: https://github.com/leeguooooo/chrome-use/issues"); } #[cfg(test)]