{"record":{"id":"4c1f0d64135bcab4","repo":"herdrdev/herdr","slug":"opening-scrollback-in-an-editor-is-not-supported-o","errorCode":null,"errorMessage":"opening scrollback in an editor is not supported on this platform","messagePattern":"opening scrollback in an editor is not supported on this platform","errorType":"error_code","errorClass":"io::Error","httpStatus":null,"severity":"warning","filePath":"src/platform/fallback.rs","lineNumber":153,"sourceCode":"    let argv = raw_command_argv(command, \"-lc\");\n    let mut command = std::process::Command::new(&argv[0]);\n    command.args(&argv[1..]);\n    command\n}\n\npub(crate) fn pane_custom_command_pty_builder_platform(\n    command: &str,\n) -> portable_pty::CommandBuilder {\n    portable_pty::CommandBuilder::from_argv(raw_command_argv(command, \"-c\"))\n}\n\npub(crate) fn interactive_shell_command(_argv: &[String], _shell_name: &str) -> Option<String> {\n    None\n}\n\n/// Unsupported platform stub.\npub(crate) fn scrollback_editor_argv(_path: &std::path::Path) -> std::io::Result<Vec<String>> {\n    Err(std::io::Error::new(\n        std::io::ErrorKind::Unsupported,\n        \"opening scrollback in an editor is not supported on this platform\",\n    ))\n}\n\n/// Unsupported platform stub.\npub fn detach_server_daemon_command(_command: &mut Command) {}\n\n/// Unsupported platform stub.\npub fn current_process_is_detached_server_daemon() -> bool {\n    false\n}\n\npub(crate) fn available_pane_shell(_child_pid: u32) -> Option<String> {\n    None\n}\n\n/// Unsupported platform stub.","sourceCodeStart":135,"sourceCodeEnd":171,"githubUrl":"https://github.com/herdrdev/herdr/blob/f457cff4f2648eee85d176f8a41861241d4e8428/src/platform/fallback.rs#L135-L171","documentation":"scrollback_editor_argv on the fallback (unsupported) platform always returns Unsupported instead of an argv for opening scrollback in an editor. It is a stub compiled for platforms where Herdr has no editor integration, so any caller attempting to open scrollback externally gets this error.","triggerScenarios":"Triggering the 'open scrollback in editor' action on a platform compiled against src/platform/fallback.rs (an OS outside windows/macos/linux/unix targets). Any keybinding or command that resolves the editor argv will immediately fail.","commonSituations":"Building Herdr for an exotic target (e.g. some BSDs, wasm, or a new OS port) that maps to the fallback platform module; attempting editor scrollback there. End users on supported platforms never see it.","solutions":["Build/run Herdr on a supported platform (Linux, macOS, Windows) where scrollback_editor_argv is implemented","If porting Herdr, implement scrollback_editor_argv in a new src/platform/<os>.rs and wire it into the platform selection","Disable or hide the open-in-editor affordance when std::io::ErrorKind::Unsupported is returned"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":"// capability probe before exposing the action\nlet supported = scrollback_editor_argv(std::path::Path::new(\"probe\"))\n    .map(|_| true)\n    .map_err(|e| e.kind() == std::io::ErrorKind::Unsupported)\n    .is_ok();","typeGuard":null,"tryCatchPattern":"match scrollback_editor_argv(path) {\n    Ok(argv) => open_editor(argv),\n    Err(e) if e.kind() == std::io::ErrorKind::Unsupported => hide_action_or_inform_user(),\n    Err(e) => log_and_report(e),\n}","preventionTips":["Gate the open-in-editor affordance on a one-time capability probe","On fallback platforms, offer copy-scrollback-to-file as an alternative","Centralize ErrorKind::Unsupported handling for all platform stubs"],"tags":["platform","unsupported","scrollback","editor","stub"],"backgroundTag":"unsupported-platform-operation","analyzedSha":"f457cff4f2648eee85d176f8a41861241d4e8428","analyzedAt":"2026-08-28T15:41:09.197Z","schemaVersion":2},"datasetVersion":"2026-08-28T16:17:29.566Z"}