{"id":"6b8c862c3bb685be","repo":"docker/cli","slug":"path-q-lacks-required-file-extension-exe","errorCode":null,"errorMessage":"path %q lacks required file extension (.exe)","messagePattern":"path %q lacks required file extension \\(\\.exe\\)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cli-plugins/manager/suffix_windows.go","lineNumber":13,"sourceCode":"package manager\n\nimport (\n\t\"fmt\"\n\t\"path/filepath\"\n\t\"strings\"\n)\n\n// This is made slightly more complex due to needing to be case-insensitive.\nfunc trimExeSuffix(s string) (string, error) {\n\text := filepath.Ext(s)\n\tif ext == \"\" || !strings.EqualFold(ext, \".exe\") {\n\t\treturn \"\", fmt.Errorf(\"path %q lacks required file extension (.exe)\", s)\n\t}\n\treturn strings.TrimSuffix(s, ext), nil\n}\n\nfunc addExeSuffix(s string) string {\n\treturn s + \".exe\"\n}\n","sourceCodeStart":1,"sourceCodeEnd":21,"githubUrl":"https://github.com/docker/cli/blob/e9452d6e785f6e365712b9d71bd7517591773c86/cli-plugins/manager/suffix_windows.go#L1-L21","documentation":"Error \"path %q lacks required file extension (.exe)\" thrown in docker/cli.","triggerScenarios":"Thrown at cli-plugins/manager/suffix_windows.go:13 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"analyzedSha":"e9452d6e785f6e365712b9d71bd7517591773c86","analyzedAt":"2026-08-01T07:09:22.474Z","schemaVersion":2}