{"record":{"id":"a6de2ddcba451cc2","repo":"helm/helm","slug":"path-q-not-found","errorCode":null,"errorMessage":"path %q not found","messagePattern":"path %q not found","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/action/install.go","lineNumber":911,"sourceCode":"\n\tname = strings.TrimSpace(name)\n\tversion := strings.TrimSpace(c.Version)\n\n\tif c.RepoURL == \"\" {\n\t\tif _, err := os.Stat(name); err == nil {\n\t\t\tabs, err := filepath.Abs(name)\n\t\t\tif err != nil {\n\t\t\t\treturn abs, err\n\t\t\t}\n\t\t\tif c.Verify {\n\t\t\t\tif _, err := downloader.VerifyChart(abs, abs+\".prov\", c.Keyring); err != nil {\n\t\t\t\t\treturn \"\", err\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn abs, nil\n\t\t}\n\t\tif filepath.IsAbs(name) || strings.HasPrefix(name, \".\") {\n\t\t\treturn name, fmt.Errorf(\"path %q not found\", name)\n\t\t}\n\t}\n\n\tdl := downloader.ChartDownloader{\n\t\tOut:     os.Stdout,\n\t\tKeyring: c.Keyring,\n\t\tGetters: getter.All(settings),\n\t\tOptions: []getter.Option{\n\t\t\tgetter.WithPassCredentialsAll(c.PassCredentialsAll),\n\t\t\tgetter.WithTLSClientConfig(c.CertFile, c.KeyFile, c.CaFile),\n\t\t\tgetter.WithInsecureSkipVerifyTLS(c.InsecureSkipTLSVerify),\n\t\t\tgetter.WithPlainHTTP(c.PlainHTTP),\n\t\t\tgetter.WithBasicAuth(c.Username, c.Password),\n\t\t},\n\t\tRepositoryConfig: settings.RepositoryConfig,\n\t\tRepositoryCache:  settings.RepositoryCache,\n\t\tContentCache:     settings.ContentCache,\n\t\tRegistryClient:   c.registryClient,","sourceCodeStart":893,"sourceCodeEnd":929,"githubUrl":"https://github.com/helm/helm/blob/2a29f1770b62844b27197d2507377361d45ad7c0/pkg/action/install.go#L893-L929","documentation":"Inside LocateChart, when no --repo is set, Helm first tries os.Stat(name); if that fails and the name looks like a local path (absolute or starting with '.'), it must be a local file - so it errors with the exact path. Relative bare names fall through to downloader resolution (URL/repo lookup), but absolute or ./-prefixed names that do not exist on disk cannot proceed.","triggerScenarios":"LocateChart or `helm install myapp /opt/charts/mychart` / `helm install myapp ./no-such-dir` where the path does not exist (typo, wrong working directory, not yet downloaded).","commonSituations":"Relative ./chart paths run from the wrong cwd (CI steps, Makefiles); referencing a chart that a previous download step failed to produce; renamed chart directories; absolute paths valid on another machine.","solutions":["Check the path exists and spelling: ls the directory you pass","For relative paths, confirm your working directory (pwd) or run helm from the chart's parent directory","If the chart should be fetched, use a repo reference (repo/chart) or URL instead of a local-looking path, or drop the leading ./ so the downloader treats it as a name","In pipelines, add a guard step that verifies the download artifact exists before helm install"],"exampleFix":"# before (wrong cwd)\nhelm install myapp ./deploy/chart   # path \"./deploy/chart\" not found\n\n# after\ncd charts && helm install myapp ./mychart","handlingStrategy":"validation","validationCode":"if filepath.IsAbs(chartRef) || strings.HasPrefix(chartRef, \".\") {\n    if _, err := os.Stat(chartRef); err != nil {\n        return fmt.Errorf(\"chart path %s does not exist (cwd=%s)\", chartRef, mustWd())\n    }\n}","typeGuard":"func isPathNotFoundErr(err error) bool {\n    return err != nil && strings.Contains(err.Error(), \"not found\") && strings.Contains(err.Error(), \"path\")\n}","tryCatchPattern":"if path, err := cpo.LocateChart(ref, settings); err != nil {\n    if isPathNotFoundErr(err) {\n        // fix cwd or the path itself; distinct from download failures which need network fixes\n    }\n    return path, err\n}","preventionTips":["Resolve chart paths to absolute paths at script start (filepath.Abs) so cwd changes cannot break later steps","Assert build artifacts exist before the helm step in CI"],"tags":["path","chart","filesystem","cli"],"backgroundTag":null,"analyzedSha":"2a29f1770b62844b27197d2507377361d45ad7c0","analyzedAt":"2026-08-15T22:02:47.490Z","schemaVersion":2},"datasetVersion":"2026-08-16T03:17:38.424Z"}