sparse-intern-71089
11/13/2022, 11:23 PMlittle-cartoon-10569
11/13/2022, 11:25 PMlittle-cartoon-10569
11/13/2022, 11:26 PMApplyT().refined-printer-32244
11/13/2022, 11:34 PMstring from a pulumi.StringOutputrefined-printer-32244
11/13/2022, 11:37 PMstring https://pkg.go.dev/github.com/pulumi/pulumi/sdk/v3/go/pulumi#StringOutput, and the inner *OutputState only seems to include ApplyT, which just returns another pulumi.Output.little-cartoon-10569
11/13/2022, 11:45 PMrefined-printer-32244
11/13/2022, 11:49 PMlittle-cartoon-10569
11/13/2022, 11:50 PMlittle-cartoon-10569
11/13/2022, 11:51 PMrefined-printer-32244
11/13/2022, 11:51 PMlittle-cartoon-10569
11/13/2022, 11:51 PMrefined-printer-32244
11/13/2022, 11:55 PMName, which requires a *string.refined-printer-32244
11/14/2022, 12:06 AMdigitalocean.LookupProjectOutput which will accept and return input/output typeslittle-cartoon-10569
11/14/2022, 12:07 AMrefined-printer-32244
11/14/2022, 12:08 AMlittle-cartoon-10569
11/14/2022, 12:09 AMrefined-printer-32244
11/14/2022, 12:09 AMApplyT on there it'll complain that it can't assign pulumi.StringOutput or pulumi.StringPtrOutput (I tried both) to a *stringlittle-cartoon-10569
11/14/2022, 12:13 AMName should be an Input, and projName is an Output. I guess my golang is not up to this problem.. I should stick with typescript...refined-printer-32244
11/14/2022, 12:15 AMpulumi.Output values, but those are subdivided into pulumi.StringOutput , etc. and then if I try to convert a pulumi.StringOutput to a string by just doing something like var myString string = myStringOutput it sounds like that should work, but it doesn'tlittle-cartoon-10569
11/14/2022, 12:33 AMlittle-cartoon-10569
11/14/2022, 12:33 AMrefined-printer-32244
11/14/2022, 12:38 AMstringrefined-printer-32244
11/14/2022, 12:38 AMbillowy-army-68599
just doing something likeyeah that unfortunately won’t ever work. You can’t assign anit sounds like that should work, but it doesn’tvar myString string = myStringOutput
StringOutput to a string unless you are inside the ApplyT.
so as an example:
// here myOutputValue is always an output
myOutputValueApplyT(func(myOutput string) string {
// here, we are inside the ApplyT function, so we have resolved the value and now it's a string
fmt.Println(myOutput)
}