{"record":{"id":"15fb7bddc0d06836","repo":"microsoft/aspire","slug":"unknown-solver-type-solver-gettype-name-on-issuer-issuer","errorCode":null,"errorMessage":"Unknown solver type '{solver.GetType().Name}' on issuer '{issuer.Name}'.","messagePattern":"Unknown solver type '(.+?)' on issuer '(.+?)'\\.","errorType":"exception","errorClass":"InvalidOperationException","httpStatus":null,"severity":"error","filePath":"src/Aspire.Hosting.Kubernetes/CertManagerExtensions.cs","lineNumber":667,"sourceCode":"                            issuer.Name,\n                            certManager.Parent.Name,\n                            issuer.Name);\n                        return;\n                    }\n\n                    sb.AppendLine(\"          parentRefs:\");\n                    foreach (var gateway in parentGateways)\n                    {\n                        sb.AppendLine(\"            - group: gateway.networking.k8s.io\");\n                        sb.AppendLine(\"              kind: Gateway\");\n                        // Match the metadata.name normalization used by BuildGatewayObjects so\n                        // the parentRef resolves to the actual Gateway in the cluster.\n                        sb.Append(\"              name: \").AppendLine(gateway.Name.ToKubernetesResourceName());\n                    }\n                    break;\n                }\n            default:\n                throw new InvalidOperationException(\n                    $\"Unknown solver type '{solver.GetType().Name}' on issuer '{issuer.Name}'.\");\n        }\n    }\n}\n","sourceCodeStart":649,"sourceCodeEnd":672,"githubUrl":"https://github.com/microsoft/aspire/blob/25830f84bd145686607ad00c057b3f84e2e51d43/src/Aspire.Hosting.Kubernetes/CertManagerExtensions.cs#L649-L672","documentation":"AppendSolver renders each challenge solver into the ClusterIssuer manifest YAML and switches on the solver's concrete type. An unrecognized solver type hits the default arm and throws InvalidOperationException naming the type and issuer, since Aspire cannot emit YAML for it.","triggerScenarios":"An issuer's Solvers collection contains a solver implementation unknown to AppendSolver — typically a custom solver added by user code or a type introduced by a newer package version than the publisher supports.","commonSituations":"Writing a custom WithDns01-style extension that adds a bespoke solver object, or a version mismatch where a solver type was added in a newer Aspire version than the one generating the manifest.","solutions":["Use the supported solver extension, e.g. WithHttp01Solver().","If you need DNS-01, use a supported DNS solver extension rather than a custom solver object.","Align package versions so solver types match the manifest generator.","Extend AppendSolver/manifest generation if you own a custom solver type."],"exampleFix":"// before\nissuer.Solvers.Add(new MyCustomDnsSolver());\n\n// after\nissuerBuilder.WithHttp01Solver();","handlingStrategy":"type-guard","validationCode":"if (solver is not Http01Solver) throw new InvalidOperationException($\"Solver type {solver.GetType().Name} not supported\");","typeGuard":"bool IsSupportedSolver(object solver) => solver is Http01Solver;","tryCatchPattern":"try { await manifestBuilder.BuildAsync(); }\ncatch (InvalidOperationException ex) when (ex.Message.StartsWith(\"Unknown solver type\")) { /* replace custom solver with WithHttp01Solver */ throw; }","preventionTips":["Add solvers only via supported extension methods like WithHttp01Solver().","Avoid custom solver implementations unless you also extend manifest generation."],"tags":["kubernetes","cert-manager","solver","unsupported-type"],"backgroundTag":"unsupported-enum-value","analyzedSha":"25830f84bd145686607ad00c057b3f84e2e51d43","analyzedAt":"2026-09-16T11:10:06.193Z","contentChangedAt":"2026-09-16T11:10:06.193Z","schemaVersion":2},"datasetVersion":"2026-09-21T09:17:21.228Z"}