-
Notifications
You must be signed in to change notification settings - Fork 16
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
Panic with control feature enabled and conditional lamdas #20
Comments
Hi @dee0sap, I think the Here is a short workaround without the control feature:
I'll try to fix this panic, but it requires some more investigation. |
Ok, the reason is tricky, I tried a quick fix, hoping it has no other consequences. working version should be:
but I think the version with the conditional operator above should be better. |
Thanks @mandelsoft ! I did end up switching to the conditional operator as it doesn't have a problem. I avoided it at first due to the number of devs out there, for reasons I cannot fathom, that claim the traditional ternary operator is hard to read. |
Running
spiff++ --features control merge i.yaml
with the file below yields a panic
panic: interface conversion: interface {} is dynaml.LambdaValue, not map[string]yaml.Node
However I am expecting
... unknown function 'getCredentials'
Sidenote... what I am wanting to do is make it possible to test the spiff files I am using in my OCM toi installer without requiring that I build a component and run the toi installer through OCM. To do that I need to somehow 'inject' a mock/lambda implementation of getCredentials.
So what I would really appreciate is anything that streamlines that.
The text was updated successfully, but these errors were encountered: