You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Feature Flags: output of getAllVariants() method cannot be associated with a flag key #68
SelectedVariant does not include any reference to the flag key for which it is a variant, so there is no way to associate the output of this method with a specific feature flag.
Mixpanel SDKs for other languages (e.g. python, node) address this by returning a dictionary that maps a flag key to variant information. So in this case, a method with a return type of Map<String, SelectedVariant<Object>> would be most consistent with other SDKs.
Hi @griswold Would it be sufficient to attach a getFlagKey() getter to SelectedVariant? This allows us to add the necessary flag key, without attempting a breaking change on the getAllVariants() return type.
Activity
tylerjroach commentedon Apr 27, 2026
Thank you for the report. We are looking into it and will get back to you.
tylerjroach commentedon Apr 27, 2026
Hi @griswold Would it be sufficient to attach a
getFlagKey()getter to SelectedVariant? This allows us to add the necessary flag key, without attempting a breaking change on thegetAllVariants()return type.griswold commentedon Apr 27, 2026
Hi @tylerjroach , thank you so much for looking at this! Yes, any way of determining the flag key would solve the problem on my side.
tylerjroach commentedon Apr 29, 2026
getAllVariantsByFlagwill go out in the next release! (1.8.1). I'll try to push it out tomorrow.tylerjroach commentedon May 1, 2026
Hi @griswold, the change is live. Please reach out if you run into any more issues. Thanks!