wet-egg-6347
09/28/2020, 8:06 PMDiagnostics:
pulumi:pulumi:Stack (bos-staging):
error: an unhandled error occurred: program exited with non-zero exit code: 2
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x17 pc=0x10997a6]
goroutine 754 [running]:
reflect.(*rtype).Kind(...)
GOROOT/src/reflect/type.go:777
reflect.convertOp(0x6efb760, 0x0, 0x109616d)
GOROOT/src/reflect/value.go:2423 +0x26
reflect.Value.Convert(0x0, 0x0, 0x0, 0x8282080, 0x6efb760, 0x199, 0x11, 0x12)
GOROOT/src/reflect/value.go:2413 +0x8a
<http://github.com/pulumi/pulumi/sdk/v2/go/pulumi.awaitInputs(0x822f700|github.com/pulumi/pulumi/sdk/v2/go/pulumi.awaitInputs(0x822f700>, 0xc0000400b8, 0x6ed4580, 0xc0000e55e0, 0x94, 0x6efb760, 0xc0004996b0, 0x199, 0x8280000, 0x0, ...)
external/com_github_pulumi_pulumi_sdk_v2/go/pulumi/types.go:700 +0x83f
<http://github.com/pulumi/pulumi/sdk/v2/go/pulumi.awaitInputs(0x822f700|github.com/pulumi/pulumi/sdk/v2/go/pulumi.awaitInputs(0x822f700>, 0xc0000400b8, 0x6fd7780, 0xc0000e5580, 0x99, 0x6faf420, 0xc0000f9f20, 0x199, 0xc000040000, 0x0, ...)
external/com_github_pulumi_pulumi_sdk_v2/go/pulumi/types.go:646 +0xdbf
<http://github.com/pulumi/pulumi/sdk/v2/go/pulumi.toOutputWithContext.func1(0x6fd7780|github.com/pulumi/pulumi/sdk/v2/go/pulumi.toOutputWithContext.func1(0x6fd7780>, 0xc0000e5580, 0x82465c0, 0xc0002e2700, 0x8282080, 0x6faf420, 0x822f700, 0xc0000400b8, 0x105b700)
external/com_github_pulumi_pulumi_sdk_v2/go/pulumi/types.go:738 +0x147
created by <http://github.com/pulumi/pulumi/sdk/v2/go/pulumi.toOutputWithContext|github.com/pulumi/pulumi/sdk/v2/go/pulumi.toOutputWithContext>
external/com_github_pulumi_pulumi_sdk_v2/go/pulumi/types.go:730 +0x1e8
lemon-agent-27707
09/28/2020, 8:36 PMwet-egg-6347
09/28/2020, 8:47 PMlemon-agent-27707
09/28/2020, 8:50 PMwet-egg-6347
09/28/2020, 8:56 PMfunc Deployment(ctx *pulumi.Context, strategy *appsv1.DeploymentStrategyArgs) {
args := &appsv1.DeploymentArgs{
Metadata: metav1.ObjectMetaArgs{
// fields omitted
},
Spec: &appsv1.DeploymentSpecArgs{
// other fields omitted
Strategy: appsv1.DeploymentStrategyPtr(strategy),
},
}
_, _ = appsv1.NewDeployment(ctx, "deploy", args)
}
when passing in nil
strategy, i was seeing the issue above
fixed by checking for if strategy == nil
rather than using the appsv1.DeploymentStrategyPtr
helper
seems like a bug-- i would've expected the appsv1.DeploymentStrategyPtr
helper to handle nils?lemon-agent-27707
09/28/2020, 9:23 PMwet-egg-6347
09/28/2020, 9:39 PM