Skip to content
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

Unexpected "Results not yet available" when "Feature Flag Response" event property is a boolean #28576

Open
danielbachhuber opened this issue Feb 11, 2025 · 0 comments
Labels
bug Something isn't working right feature/experimentation Feature Tag: Experimentation

Comments

@danielbachhuber
Copy link
Contributor

danielbachhuber commented Feb 11, 2025

Bug Description

If the first feature flag you use is a boolean, then the "Feature Flag Response" event property can be set to a boolean.

Then, when you try to run an experiment later on, the query can fail with:

DB::Exception: Cannot parse boolean value here: 'control', should be 'true' or 'false' controlled by setting bool_true_representation and bool_false_representation or one of True/False/T/F/Y/N/Yes/No/On/Off/Enable/Disable/Enabled/Disabled/1/0: while converting 'control' to Bool: while executing 'FUNCTION equals(toBool(transform(toString(nullIf(nullIf(mat_$feature_flag_response, ''), 'null')), ['true', 'false'], [1, 0], NULL)) : 72, 'control' : 30) -> equals(toBool(transform(toString(nullIf(nullIf(mat_$feature_flag_response, ''), 'null')), ['true', 'false'], [1, 0], NULL)), 'control') Nullable(UInt8) : 73'. Stack trace:

The easy fix is to change "Feature Flag Response" to a string. We should probably help customers avoid this scenario, though.

Debug info

- [ ] PostHog Cloud, Debug information: [please copy/paste from https://us.posthog.com/settings/project-details#variables or https://eu.posthog.com/settings/project-details#variables]
- [ ] PostHog Hobby self-hosted with `docker compose`, version/commit: [please provide]
- [ ] PostHog self-hosted with Kubernetes (deprecated, see [`Sunsetting Kubernetes support`](https://posthog.com/blog/sunsetting-helm-support-posthog)), version/commit: [please provide]
@danielbachhuber danielbachhuber added bug Something isn't working right feature/experimentation Feature Tag: Experimentation labels Feb 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working right feature/experimentation Feature Tag: Experimentation
Projects
None yet
Development

No branches or pull requests

1 participant