{"record":{"id":"ac5ee239ab26de2c","repo":"GoogleContainerTools/skaffold","slug":"parsing-dependencies-for-skaffold-config-s-w","errorCode":null,"errorMessage":"parsing dependencies for skaffold config %s: %w","messagePattern":"parsing dependencies for skaffold config (.+?): %w","errorType":"console","errorClass":"ConfigParsingError","httpStatus":null,"severity":"error","filePath":"pkg/skaffold/parser/config.go","lineNumber":337,"sourceCode":"\t\tcachePath, err := cacheGCSObject(ctx, *d.GoogleCloudStorage, opts, r)\n\t\tif err != nil {\n\t\t\treturn nil, sErrors.ConfigParsingError(fmt.Errorf(\"caching remote dependency %s: %w\", d.GoogleCloudStorage.Path, err))\n\t\t}\n\t\tpath = cachePath\n\t\tisRemoteCfg = true\n\t}\n\n\tif path == \"\" {\n\t\t// empty path means configs in the same file\n\t\tpath = cfgOpts.file\n\t}\n\tif !util.IsURL(path) {\n\t\tfi, err := os.Stat(path)\n\t\tif err != nil {\n\t\t\tif errors.Is(err, os.ErrNotExist) {\n\t\t\t\treturn nil, sErrors.DependencyConfigFileNotFoundErr(path, cfgOpts.file, err)\n\t\t\t}\n\t\t\treturn nil, sErrors.ConfigParsingError(fmt.Errorf(\"parsing dependencies for skaffold config %s: %w\", cfgOpts.file, err))\n\t\t}\n\t\tif fi.IsDir() {\n\t\t\tpath = filepath.Join(path, \"skaffold.yaml\")\n\t\t}\n\t}\n\n\t// if the current and previous configuration files are the same, then current config should be treated as a dependency config if the previous config was also a dependency config.\n\t// Otherwise the current config is always a dependency config if the file path is different than the previous.\n\tcfgOpts.isDependency = cfgOpts.isDependency || path != cfgOpts.file\n\tcfgOpts.file = path\n\tcfgOpts.selection = d.Names\n\tcfgOpts.isRemote = isRemoteCfg\n\tdepConfigs, _, err := getConfigs(ctx, cfgOpts, opts, r)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn depConfigs, nil\n}","sourceCodeStart":319,"sourceCodeEnd":355,"githubUrl":"https://github.com/GoogleContainerTools/skaffold/blob/a1189de023efc32d4b8e11f395acc678aa555011/pkg/skaffold/parser/config.go#L319-L355","documentation":"After resolving a dependency path, Skaffold calls os.Stat on local (non-URL) dependency paths. If Stat fails with an error other than not-exist (not-exist gets its own DependencyConfigFileNotFoundErr), the stat error is wrapped in ConfigParsingError with this message. It means the dependency file exists in intent but cannot be accessed or inspected by the process.","triggerScenarios":"processEachDependency stats a local dependency path that yields a non-ErrNotExist error: permission denied on the file or a parent directory, an I/O error, path too long, or the path being a broken special file.","commonSituations":"A dependency skaffold.yaml owned by another user with 0600 permissions; read-protected parent directories in multi-module repos; NFS/USB mount dropped; running skaffold in a container as a different UID.","solutions":["Check permissions: ls -l <path> and the parent directories; fix with chmod/chown or run as a user with access","Confirm the path is accessible from the environment skaffold runs in (container user, mount is mounted)","Re-run to rule out a transient I/O error","If the file is actually missing, fix the path so the correct not-found error path applies instead"],"exampleFix":"// before\nrequires:\n  - path: /secure/configs/skaffold.yaml   # 0600 root-owned\n// after\nchmod 644 /secure/configs/skaffold.yaml\n# or copy it into the repo\nrequires:\n  - path: ./configs/skaffold.yaml","handlingStrategy":"validation","validationCode":"for p in $(yq '.requires[].path' skaffold.yaml); do\n  [ -r \"$p\" ] || echo \"unreadable dependency: $p\"\ndone","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Check file and parent-directory read permissions for the user running skaffold","Keep dependency configs inside the repo with normal 0644 permissions","In containers, run as a UID that owns or can read mounted config volumes","Verify mounts (NFS/USB) are up before running pipelines"],"tags":["filesystem","permissions","config-parsing"],"backgroundTag":"config-file-access-denied","analyzedSha":"a1189de023efc32d4b8e11f395acc678aa555011","analyzedAt":"2026-09-05T12:09:27.064Z","contentChangedAt":"2026-09-05T12:09:27.064Z","schemaVersion":2},"datasetVersion":"2026-09-12T17:17:11.597Z"}