-
Notifications
You must be signed in to change notification settings - Fork 115
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
[dotnet] Unknowns for previews involving an uninitialized provider #2957
Conversation
Does the PR have any schema changes?Looking good! No breaking changes found. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #2957 +/- ##
=======================================
Coverage 29.18% 29.18%
=======================================
Files 61 61
Lines 8196 8196
=======================================
Hits 2392 2392
Misses 5600 5600
Partials 204 204 ☔ View full report in Codecov by Sentry. |
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.
The fix and regression test LGTM!
It's worth updating the changelog since this is user-facing.
This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [@pulumi/kubernetes](https://pulumi.com) ([source](https://togithub.com/pulumi/pulumi-kubernetes)) | dependencies | minor | [`4.10.0` -> `4.11.0`](https://renovatebot.com/diffs/npm/@pulumi%2fkubernetes/4.10.0/4.11.0) | --- > [!WARNING] > Some dependencies could not be looked up. Check the Dependency Dashboard for more information. --- ### Release Notes <details> <summary>pulumi/pulumi-kubernetes (@​pulumi/kubernetes)</summary> ### [`v4.11.0`](https://togithub.com/pulumi/pulumi-kubernetes/blob/HEAD/CHANGELOG.md#4110-April-17-2024) [Compare Source](https://togithub.com/pulumi/pulumi-kubernetes/compare/v4.10.0...v4.11.0) - \[dotnet] Unknowns for previews involving an uninitialized provider [https://github.com/pulumi/pulumi-kubernetes/pull/2957](https://togithub.com/pulumi/pulumi-kubernetes/pull/2957)7) - Update Kubernetes schemas and libraries to v1.30.0 ([https://github.com/pulumi/pulumi-kubernetes/pull/2932](https://togithub.com/pulumi/pulumi-kubernetes/pull/2932)) </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://togithub.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zMDMuMiIsInVwZGF0ZWRJblZlciI6IjM3LjMwMy4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJ0eXBlL21pbm9yIl19--> Co-authored-by: lumiere-bot[bot] <98047013+lumiere-bot[bot]@users.noreply.github.com>
Proposed changes
This PR fixes the "panic" that occurs when an uninitialized provider is used with the yaml/kustomize resources. In that situation, the invoke calls aren't performed and the engine simply returns an uninitialized result. This causes a problem in the callers because the methods on
ImmutableArray
mustn't be used when the value is uninitialized (i.e. whenIsDefault
is true).Example
The example given in #2741 easily repros the issue. With this fix, the behavior improves:
Testing
Includes integration tests involving an uninitialized provider with a
ConfigFile
orDirectory
.Related issues (optional)
Closes #2741