-
Notifications
You must be signed in to change notification settings - Fork 113
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
AllowNullValues causes a panic when there's a null value #2622
Labels
area/helm
impact/panic
This bug represents a panic or unexpected crash
kind/bug
Some behavior is incorrect or out of spec
p1
A bug severe enough to be the next item assigned to an engineer
resolution/fixed
This issue was fixed
Milestone
Comments
martinjt
added
kind/bug
Some behavior is incorrect or out of spec
needs-triage
Needs attention from the triage team
labels
Oct 23, 2023
martinjt
changed the title
AllowNullValues throws error when there's a null value
AllowNullValues causes a panic when there's a null value
Oct 23, 2023
mikhailshilkov
added
p1
A bug severe enough to be the next item assigned to an engineer
impact/panic
This bug represents a panic or unexpected crash
and removed
needs-triage
Needs attention from the triage team
labels
Oct 24, 2023
I am able to reproduce the issue. Here's some relevant background:
Seems like #2220 may have caused a regression, for at least one variation that I haven't isolated yet. |
6 tasks
The minimal fix for this issue is here: pulumi/pulumi#14498 In the course of investigating this issue, I do see some fidelity issues related to empty lists and nulls:
|
github-merge-queue bot
pushed a commit
to pulumi/pulumi
that referenced
this issue
Nov 4, 2023
<!--- Thanks so much for your contribution! If this is your first time contributing, please ensure that you have read the [CONTRIBUTING](https://github.com/pulumi/pulumi/blob/master/CONTRIBUTING.md) documentation. --> # Description Fixes a panic that occurs when attempting to encode certain values, for example a map that contains a nil value: ```go bag := bagtag{ String: "something", StringOpt: "ohmv", MapOpt: map[string]interface{}{ "a": "something", "b": nil, // this reflect.Value is of type Interface and IsNil is true. }, } _ = resource.NewPropertyMap(bag) // panic here ``` New tests are provided to cover the above scenario and to cover each type of value, including nil cases where appropriate. Fixes: pulumi/pulumi-kubernetes#2622 Follow-up to: #9810 ## Checklist - [x] I have run `make tidy` to update any new dependencies - [x] I have run `make lint` to verify my code passes the lint check - [ ] I have formatted my code using `gofumpt` <!--- Please provide details if the checkbox below is to be left unchecked. --> - [x] I have added tests that prove my fix is effective or that my feature works <!--- User-facing changes require a CHANGELOG entry. --> - [x] I have run `make changelog` and committed the `changelog/pending/<file>` documenting my change <!-- If the change(s) in this PR is a modification of an existing call to the Pulumi Cloud, then the service should honor older versions of the CLI where this change would not exist. You must then bump the API version in /pkg/backend/httpstate/client/api.go, as well as add it to the service. --> - [ ] Yes, there are changes in this PR that warrants bumping the Pulumi Cloud API version <!-- @pulumi employees: If yes, you must submit corresponding changes in the service repo. -->
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
area/helm
impact/panic
This bug represents a panic or unexpected crash
kind/bug
Some behavior is incorrect or out of spec
p1
A bug severe enough to be the next item assigned to an engineer
resolution/fixed
This issue was fixed
What happened?
When I add this:
To a helm values file, with the setting
AllowNullValues
on the resource, I get an exception when applying.Example
More complete example here: https://github.com/martinjt/aks-otel-demo
Output of
pulumi about
The text was updated successfully, but these errors were encountered: