{"record":{"id":"0aa845f019a21941","repo":"argoproj/argo-workflows","slug":"failed-to-load-artifact-s-w","errorCode":null,"errorMessage":"failed to load artifact '%s': %w","messagePattern":"failed to load artifact '(.+?)': %w","errorType":"error_code","errorClass":null,"httpStatus":null,"severity":"error","filePath":"workflow/executor/executor.go","lineNumber":285,"sourceCode":"\nfunc (we *WorkflowExecutor) loadArtifact(ctx context.Context, pluginName wfv1.ArtifactPluginName, art wfv1.Artifact) error {\n\tlogger := logging.RequireLoggerFromContext(ctx)\n\tlogger.WithField(\"name\", art.Name).Info(ctx, \"Downloading artifact\")\n\n\tif !art.HasLocationOrKey() {\n\t\tif art.Optional {\n\t\t\tlogger.WithField(\"name\", art.Name).Info(ctx, \"Ignoring optional artifact which was not supplied\")\n\t\t\treturn nil\n\t\t}\n\t\treturn argoerrs.Errorf(argoerrs.CodeNotFound, \"required artifact '%s' not supplied\", art.Name)\n\t}\n\terr := art.CleanPath()\n\tif err != nil {\n\t\treturn err\n\t}\n\tdriverArt, err := we.newDriverArt(&art)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"failed to load artifact '%s': %w\", art.Name, err)\n\t}\n\tswitch pluginName {\n\t// If no plugin is specified only load non-plugin artifacts\n\tcase \"\":\n\t\tif driverArt.Plugin != nil {\n\t\t\tlogger.Info(ctx, \"Skipping artifact that is from a plugin\")\n\t\t\treturn nil\n\t\t}\n\t\t// If a plugin is specified only load artifacts from that plugin\n\tdefault:\n\t\tif driverArt.Plugin == nil || driverArt.Plugin.Name != pluginName {\n\t\t\tlogger.WithFields(logging.Fields{\"name\": driverArt.Name, \"plugin\": driverArt.Plugin}).Info(ctx, \"Skipping artifact that is not from the specified plugin\")\n\t\t\treturn nil\n\t\t}\n\t}\n\n\tartDriver, err := we.InitDriver(ctx, driverArt)\n\tif err != nil {","sourceCodeStart":267,"sourceCodeEnd":303,"githubUrl":"https://github.com/argoproj/argo-workflows/blob/35bff19146f5a6ada77468c431f2624bd577e373/workflow/executor/executor.go#L267-L303","documentation":"loadArtifact converts a workflow artifact spec into a driver artifact via newDriverArt before handing it to the storage driver. If that conversion fails (e.g. the artifact's config/secret cannot be resolved), the error is wrapped as 'failed to load artifact <name>: <cause>'.","triggerScenarios":"newDriverArt fails while resolving the artifact — typically a missing/misreferenced storage secret (s3/gcs/azure accessKey/secretKey), an invalid artifact spec, or an artifact-sources plugin lookup failure.","commonSituations":"Input artifact referencing a secretKeyRef that doesn't exist in the namespace; S3 bucket misconfigured in the artifact repository config; artifact defined with a plugin source but no plugin loaded; typo'd bucket/endpoint config.","solutions":["Inspect the wrapped cause: usually a missing secret — create the referenced secret in the workflow namespace","Verify the artifact repository configuration (default configs in the controller configmap) and credentials","If the artifact comes from a plugin, confirm that plugin is loaded by the executor","Use `argo lint` and check that the artifact name/spec in the template matches the artifact repository schema"],"exampleFix":"# before (artifact references missing secret)\nartifacts:\n  - name: data\n    s3:\n      key: my/key\n      accessKeySecret:\n        name: s3-creds   # does not exist\n# after\nartifacts:\n  - name: data\n    s3:\n      key: my/key\n      accessKeySecret:\n        name: s3-creds\n        key: accessKey   # secret created in namespace","handlingStrategy":"validation","validationCode":"# Ensure referenced secrets exist before submitting:\n# kubectl get secret s3-creds -n <namespace>\n# and validate the workflow:\n# argo lint workflow.yaml","typeGuard":null,"tryCatchPattern":"if err := loadArtifacts(ctx); err != nil {\n\tif strings.Contains(err.Error(), \"failed to load artifact\") {\n\t\t// check wrapped cause: missing secret vs invalid spec\n\t}\n}","preventionTips":["Create all storage secrets (accessKeySecret/secretKeySecret) in the workflow namespace before submit","Validate the artifact repository configuration in the controller configmap","Confirm plugin-sourced artifacts have their plugin loaded","Lint workflows (`argo lint`) to catch malformed artifact specs"],"tags":["artifacts","executor","secrets","configuration"],"backgroundTag":"artifact-load-failed","analyzedSha":"35bff19146f5a6ada77468c431f2624bd577e373","analyzedAt":"2026-09-03T19:34:35.908Z","contentChangedAt":"2026-09-03T19:34:35.908Z","schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}