Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow resource names that conflict with extra types #11244

Merged
merged 1 commit into from Nov 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
@@ -0,0 +1,4 @@
changes:
- type: fix
scope: sdkgen/go
description: Allow resource names that conflict with additional types.
4 changes: 4 additions & 0 deletions pkg/codegen/go/gen.go
Expand Up @@ -3223,6 +3223,10 @@ func generatePackageContextMap(tool string, pkg *schema.Package, goInfo GoPackag
names = append(names, cgstrings.Camel(rawResourceName(r))+suffix+"State")
names = append(names, "Get"+rawResourceName(r)+suffix)
}
if goInfo.GenerateResourceContainerTypes && !r.IsProvider {
names = append(names, rawResourceName(r)+suffix+"Array")
names = append(names, rawResourceName(r)+suffix+"Map")
}
return names
}

Expand Down
Expand Up @@ -3,6 +3,10 @@
"repro/doc.go",
"repro/foo.go",
"repro/init.go",
"repro/overlap/consumer.go",
"repro/overlap/init.go",
"repro/overlap/someType.go",
"repro/overlap/someTypeMap.go",
"repro/provider.go",
"repro/pulumi-plugin.json",
"repro/pulumiTypes.go",
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.