{"record":{"id":"a3ccbe42068d522b","repo":"pulumi/pulumi","slug":"generateprogram-is-not-supported","errorCode":null,"errorMessage":"GenerateProgram is not supported","messagePattern":"GenerateProgram is not supported","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"pkg/resource/deploy/deploytest/languageruntime.go","lineNumber":206,"sourceCode":"\treturn nil, nil, nil, errors.New(\"inline plugins are not currently supported\")\n}\n\nfunc (p *languageRuntime) GenerateProject(context.Context, string, string, string,\n\tbool, string, map[string]string,\n) (hcl.Diagnostics, error) {\n\treturn nil, errors.New(\"GenerateProject is not supported\")\n}\n\nfunc (p *languageRuntime) GeneratePackage(context.Context,\n\tstring, string, map[string][]byte, string, map[string]string, bool,\n) (hcl.Diagnostics, error) {\n\treturn nil, errors.New(\"GeneratePackage is not supported\")\n}\n\nfunc (p *languageRuntime) GenerateProgram(\n\tcontext.Context, map[string]string, string, bool,\n) (map[string][]byte, hcl.Diagnostics, error) {\n\treturn nil, nil, errors.New(\"GenerateProgram is not supported\")\n}\n\nfunc (p *languageRuntime) Pack(context.Context, string, string) (string, error) {\n\treturn \"\", errors.New(\"Pack is not supported\")\n}\n\nfunc (p *languageRuntime) Link(\n\tcontext.Context, plugin.ProgramInfo, []workspace.LinkablePackageDescriptor, string,\n) (string, error) {\n\treturn \"\", errors.New(\"Link is not supported\")\n}\n\nfunc (p *languageRuntime) Cancel(context.Context) error {\n\tp.closed = true\n\n\tif p.shutdown != nil {\n\t\tp.shutdown()\n\t}","sourceCodeStart":188,"sourceCodeEnd":224,"githubUrl":"https://github.com/pulumi/pulumi/blob/793f7b2e160db4321fb7fb6b0607461e01cb251e/pkg/resource/deploy/deploytest/languageruntime.go#L188-L224","documentation":"The deploytest languageRuntime stub does not implement program generation/conversion. GenerateProgram normally converts program sources (e.g. between languages or PCL); the fake runtime always fails. It is a placeholder to satisfy the plugin.LanguageRuntime interface for tests.","triggerScenarios":"Calling GenerateProgram on the deploytest runtime, e.g. `pulumi convert`-style tests or any engine flow that asks the language runtime to translate program code.","commonSituations":"Testing program conversion with the mock runtime; accidental use of deploytest host in conversion codepaths.","solutions":["Test conversion via pkg/codegen/pcl and the real convert pipeline instead of the stub runtime.","Use a real language runtime host when testing conversion end-to-end.","Skip program-generation steps in tests that only verify deployment behavior."],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":"if _, diags, err := runtime.GenerateProgram(ctx, ...); err != nil && strings.Contains(err.Error(), \"GenerateProgram is not supported\") {\n    // use the convert pipeline / real runtime instead\n}","preventionTips":["Avoid conversion workflows in deploytest tests","Test pcl/convert directly in pkg/codegen"],"tags":["go","testing","conversion","unimplemented"],"backgroundTag":"unimplemented-in-test-stub","analyzedSha":"793f7b2e160db4321fb7fb6b0607461e01cb251e","analyzedAt":"2026-08-31T09:36:43.099Z","schemaVersion":2},"datasetVersion":"2026-09-01T08:17:40.651Z"}