Skip to content

Fix Go program generation lifting plains to input values#22084

Merged
Frassle merged 3 commits intomasterfrom
fraser/liftgo
Mar 5, 2026
Merged

Fix Go program generation lifting plains to input values#22084
Frassle merged 3 commits intomasterfrom
fraser/liftgo

Conversation

@Frassle
Copy link
Copy Markdown
Member

@Frassle Frassle commented Mar 4, 2026

This fixes Go program generation to lift plain values like string to input/output values like pulumi.String in locations that is needed. Most directly this fixes the generation of the l1-builtin-secret test for Go as we now correctly lift the notSecret value to be a pulumi.String.

As part of this I had to fix the readFile helper function to match what PCL binding expected it to be, a plain string, not an output string. This is so PCL binding added the correct __convert calls, rather than it thinking readFile returned a string, trying to cast it to an input and then failing because the Go helper was already an output.

@Frassle Frassle force-pushed the fraser/liftgo branch 2 times, most recently from 283e712 to e07f304 Compare March 5, 2026 09:02
@Frassle Frassle marked this pull request as ready for review March 5, 2026 09:56
@Frassle Frassle requested a review from a team as a code owner March 5, 2026 09:56
Comment thread pkg/codegen/go/gen_program_expressions.go Outdated
Co-authored-by: Ian Wahbe <me@iwahbe.com>
@Frassle Frassle enabled auto-merge March 5, 2026 13:27
@Frassle Frassle added this pull request to the merge queue Mar 5, 2026
Merged via the queue into master with commit 46eee5c Mar 5, 2026
211 of 213 checks passed
@Frassle Frassle deleted the fraser/liftgo branch March 5, 2026 14:59
@pulumi-bot
Copy link
Copy Markdown
Contributor

This PR has been shipped in release v3.225.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants