{"record":{"id":"6ec76531171eddf5","repo":"goreleaser/goreleaser","slug":"could-not-evaluate-mcp-disable-w","errorCode":null,"errorMessage":"could not evaluate mcp.disable: %w","messagePattern":"could not evaluate mcp\\.disable: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/pipe/mcp/mcp.go","lineNumber":77,"sourceCode":"\t\tctx.Config.MCP.Description = ctx.Config.MCP.GitHub.Description\n\t\tctx.Config.MCP.Homepage = ctx.Config.MCP.GitHub.Homepage\n\t\tctx.Config.MCP.Packages = ctx.Config.MCP.GitHub.Packages\n\t\tctx.Config.MCP.Transports = ctx.Config.MCP.GitHub.Transports\n\t\tctx.Config.MCP.Disable = ctx.Config.MCP.GitHub.Disable\n\t\tctx.Config.MCP.Repository = ctx.Config.MCP.GitHub.Repository\n\t\tctx.Config.MCP.Auth = ctx.Config.MCP.GitHub.Auth\n\t}\n\n\tctx.Config.MCP.Auth.Type = cmp.Or(ctx.Config.MCP.Auth.Type, proto.MethodNone)\n\treturn nil\n}\n\nfunc (p Pipe) Publish(ctx *context.Context) error {\n\tmcp := ctx.Config.MCP\n\n\tdisable, err := tmpl.New(ctx).Apply(mcp.Disable)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"could not evaluate mcp.disable: %w\", err)\n\t}\n\tif strings.TrimSpace(disable) == \"true\" {\n\t\treturn pipe.Skip(\"mcp.disable is set\")\n\t}\n\tif strings.TrimSpace(disable) == \"auto\" && ctx.Semver.Prerelease != \"\" {\n\t\treturn pipe.Skip(\"prerelease detected with 'auto' disable, skipping mcp publish\")\n\t}\n\n\twarnExperimental()\n\n\tif err := tmpl.New(ctx).ApplyAll(\n\t\t&mcp.Name,\n\t\t&mcp.Description,\n\t\t&mcp.Title,\n\t\t&mcp.Homepage,\n\t\t&mcp.Repository.URL,\n\t\t&mcp.Repository.Source,\n\t\t&mcp.Repository.ID,","sourceCodeStart":59,"sourceCodeEnd":95,"githubUrl":"https://github.com/goreleaser/goreleaser/blob/f5edd7395693c0c6b501dc722d445d2e86af854d/internal/pipe/mcp/mcp.go#L59-L95","documentation":"Wrapped error in the MCP pipe's Publish: templating the mcp.disable field (from mcp.disable or mcp.github.disable) failed. The boolean/string skip decision is templated before warnExperimental and any publish work; the %w chain identifies the invalid template expression.","triggerScenarios":"Thrown at internal/pipe/mcp/mcp.go:77 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Fix the mcp.disable template expression so it evaluates to a valid boolean/string","Use only available template fields in the disable expression","Test with `goreleaser release --snapshot` to validate template evaluation early"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"f5edd7395693c0c6b501dc722d445d2e86af854d","analyzedAt":"2026-09-05T09:57:18.807Z","contentChangedAt":"2026-09-05T09:57:18.807Z","schemaVersion":2},"datasetVersion":"2026-09-12T12:17:11.808Z"}