Closed thomaspoignant closed 1 year ago
I am using nil as a default value while calling client.ObjectValueDetails but when doing this everytime if the default value is used we receive no ResolutionDetail from the SDK.
nil
client.ObjectValueDetails
ResolutionDetail
After looking a bit at the SDK it seems that we add the ResolutionDetail only if the value is not nil. https://github.com/open-feature/go-sdk/blob/fd678bd263eb532942c4777f4eed8e26a6e52694/pkg/openfeature/client.go#L642
value
It means that we cannot use nil as value in the SDK.
I would like to be able to use nil as value for my flag.
SDK return a flag with a nil value.
I think this is a valid use case, in other SDKs null (or Value constructs representing null) are supported.
null
Value
Observed behavior
I am using
nil
as a default value while callingclient.ObjectValueDetails
but when doing this everytime if the default value is used we receive noResolutionDetail
from the SDK.After looking a bit at the SDK it seems that we add the
ResolutionDetail
only if thevalue
is not nil. https://github.com/open-feature/go-sdk/blob/fd678bd263eb532942c4777f4eed8e26a6e52694/pkg/openfeature/client.go#L642It means that we cannot use
nil
asvalue
in the SDK.Expected Behavior
I would like to be able to use
nil
as value for my flag.Steps to reproduce
SDK return a flag with a
nil
value.