{"record":{"id":"391e7c2a63a50f9c","repo":"LGUG2Z/komorebi","slug":"could-not-find-file","errorCode":null,"errorMessage":"could not find file: {}","messagePattern":"could not find file: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"komorebic/src/main.rs","lineNumber":2418,"sourceCode":"                        stdout if !stdout.contains(\"scoop\") => None,\n                        stdout => {\n                            buf = PathBuf::from(stdout);\n                            buf.pop(); // %USERPROFILE%\\scoop\\shims\n                            buf.pop(); // %USERPROFILE%\\scoop\n                            buf.push(\"apps\\\\komorebi\\\\current\\\\komorebi.exe\"); //%USERPROFILE%\\scoop\\komorebi\\current\\komorebi.exe\n                            Some(buf.to_str().ok_or_eyre(\n                                \"cannot create a string from the scoop komorebi path\",\n                            )?)\n                        }\n                    }\n                } else {\n                    None\n                };\n\n            let mut flags = vec![];\n            if let Some(config) = &args.config {\n                if !config.is_file() {\n                    bail!(\"could not find file: {}\", config.display());\n                }\n\n                let config = dunce::simplified(config);\n                flags.push(format!(\"'--config=\\\"{}\\\"'\", config.display()));\n            }\n\n            if args.ffm {\n                flags.push(\"'--ffm'\".to_string());\n            }\n\n            if args.await_configuration {\n                flags.push(\"'--await-configuration'\".to_string());\n            }\n\n            if let Some(port) = args.tcp_port {\n                flags.push(format!(\"'--tcp-port={port}'\"));\n            }\n","sourceCodeStart":2400,"sourceCodeEnd":2436,"githubUrl":"https://github.com/LGUG2Z/komorebi/blob/e0709f02bfae4e503bf4640f58ee75ecbbfdbb97/komorebic/src/main.rs#L2400-L2436","documentation":"Returned when komorebic is asked to read a file path that does not exist on disk (the formatting string receives the offending path). It is a straightforward existence check on user-supplied file input (e.g. a config file passed to a subcommand); the operation cannot proceed without the file.","triggerScenarios":"Thrown at komorebic/src/main.rs:2418 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Verify the path in the message is spelled correctly and use an absolute path if needed","Create the missing file or point the command at an existing one","Check permissions/working directory if the file is expected to exist"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"e0709f02bfae4e503bf4640f58ee75ecbbfdbb97","analyzedAt":"2026-09-06T07:08:05.107Z","contentChangedAt":"2026-09-06T07:08:05.107Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}