{"id":"534683abc2458df8","repo":"docker/cli","slug":"invalid-type-t-for-secret","errorCode":null,"errorMessage":"invalid type %T for secret","messagePattern":"invalid type %T for secret","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cli/compose/loader/loader.go","lineNumber":747,"sourceCode":"\t\t\t\tports = append(ports, value)\n\t\t\tdefault:\n\t\t\t\treturn data, fmt.Errorf(\"invalid type %T for port\", value)\n\t\t\t}\n\t\t}\n\t\treturn ports, nil\n\tdefault:\n\t\treturn data, fmt.Errorf(\"invalid type %T for port\", entries)\n\t}\n}\n\nvar transformStringSourceMap TransformerFunc = func(data any) (any, error) {\n\tswitch value := data.(type) {\n\tcase string:\n\t\treturn map[string]any{\"source\": value}, nil\n\tcase map[string]any:\n\t\treturn data, nil\n\tdefault:\n\t\treturn data, fmt.Errorf(\"invalid type %T for secret\", value)\n\t}\n}\n\nvar transformBuildConfig TransformerFunc = func(data any) (any, error) {\n\tswitch value := data.(type) {\n\tcase string:\n\t\treturn map[string]any{\"context\": value}, nil\n\tcase map[string]any:\n\t\treturn data, nil\n\tdefault:\n\t\treturn data, fmt.Errorf(\"invalid type %T for service build\", value)\n\t}\n}\n\nvar transformServiceVolumeConfig TransformerFunc = func(data any) (any, error) {\n\tswitch value := data.(type) {\n\tcase string:\n\t\treturn volumespec.Parse(value)","sourceCodeStart":729,"sourceCodeEnd":765,"githubUrl":"https://github.com/docker/cli/blob/e9452d6e785f6e365712b9d71bd7517591773c86/cli/compose/loader/loader.go#L729-L765","documentation":"Error \"invalid type %T for secret\" thrown in docker/cli.","triggerScenarios":"Thrown at cli/compose/loader/loader.go:747 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}