-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[codegen/go] Fix secret codegen for input properties #9052
Conversation
#7128 added code to mark properties as secret based on a schema flag, but did not correctly handle the case where output properties do not have a corresponding input property. In this case, code was generated for nonexistent input properties, and would lead to a panic.
Diff for pulumi-random with merge commit 53a61dd |
Diff for pulumi-azuread with merge commit 53a61dd |
Diff for pulumi-kubernetes with merge commit 53a61dd |
Diff for pulumi-gcp with merge commit 53a61dd |
Diff for pulumi-azure with merge commit 53a61dd |
Diff for pulumi-aws with merge commit 53a61dd |
Diff for pulumi-azure-native with merge commit 53a61dd |
Diff for pulumi-random with merge commit a1c62e8 |
Diff for pulumi-azuread with merge commit a1c62e8 |
Diff for pulumi-kubernetes with merge commit a1c62e8 |
Diff for pulumi-gcp with merge commit a1c62e8 |
Diff for pulumi-azure with merge commit a1c62e8 |
Diff for pulumi-aws with merge commit a1c62e8 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM otherwise.
@@ -27,9 +27,6 @@ func NewCat(ctx *pulumi.Context, | |||
args = &CatArgs{} | |||
} | |||
|
|||
if args.Name != nil { | |||
args.Name = pulumi.ToSecret(args.Name).(pulumi.StringPtrOutput) | |||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this mean we can delete the SkipCompileCheck
for Go for this test now?
pulumi/pkg/codegen/testing/test/sdk_driver.go
Line 158 in a1e18da
SkipCompileCheck: codegen.NewStringSet(golang), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, perhaps. I'll give it a shot.
Diff for pulumi-azure-native with merge commit a1c62e8 |
Diff for pulumi-random with merge commit c6cbaeb |
Diff for pulumi-azuread with merge commit c6cbaeb |
Diff for pulumi-kubernetes with merge commit c6cbaeb |
Diff for pulumi-gcp with merge commit c6cbaeb |
Diff for pulumi-azure with merge commit c6cbaeb |
Diff for pulumi-aws with merge commit c6cbaeb |
Diff for pulumi-azure-native with merge commit c6cbaeb |
Diff for pulumi-random with merge commit cec12cc |
Diff for pulumi-azuread with merge commit cec12cc |
Diff for pulumi-kubernetes with merge commit cec12cc |
Diff for pulumi-gcp with merge commit cec12cc |
Diff for pulumi-azure with merge commit cec12cc |
Diff for pulumi-aws with merge commit cec12cc |
Diff for pulumi-azure-native with merge commit cec12cc |
Pulls in fixes from pulumi/pulumi#9052 Signed-off-by: Noel Georgi <git@frezbo.dev>
This reverts commit 301efa6.
Description
#7128 added code to mark properties as secret based on a schema flag, but did not correctly handle the case where output properties do not have a corresponding input property. In this case, code was generated for nonexistent input properties, and would lead to a panic.
Fixes #8967
Checklist