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
toToml filter converts int to float #12987
Comments
Lines 125 to 133 in c6beb16
Either Helm is representing the value internally as float, and toToml is rendering that. Or the design decision/issue with rendering ints as floats lies upstream with github.com/BurntSushi/toml. The former should be determined first I think. |
IIRC, the internal representation is float. #6010 was made to use It seems like the toml module supports |
I made a draft PR to demonstrate this (just an easy way to share code), but adding unit tests for the |
That said, I did repro this issue. I did
copied their values:
and then
I added this repro to my demo PR as a failing test in the |
I was able to trace this to the function |
Given the following data structure in values.yaml:
And this in my configmap template:
I get this:
Even casting the variable via bar:
!!int 9
doesn't change the behavior, can't reproduce using the toJson filter either.I'm running Helm version.BuildInfo{Version:"v3.14.4", GitCommit:"81c902a123462fd4052bc5e9aa9c513c4c8fc142", GitTreeState:"clean", GoVersion:"go1.21.9"}
The text was updated successfully, but these errors were encountered: