Commit 14a2f80
authored
feat(flags): Add more details such as version, id, and reason to
* Flesh out Decide response types
* Ensure we normalize get_decide
In a back compat manner.
* Populate feature_flags_by_key when setting feature_flags
Since `self.feature_flags_by_key` is derived from `self.feature_flags`, and we often set the latter in unit tests, but forget to set the former, our tests can be wonky.
This ensures that when we set `self.feature_flags`, we always set `self. feature_flags_by_key`
* Annotate types
* Lookup local flag by key
Fixes #121
* Refactor local flag evaluation into its own method
* Include extra details in `$feature_flag_called` events
* Fix up type annotations, tests, and formatting
* Update lib to decide v4
* Bump version and add changelog$feature_flag_called events (#207)1 parent 2779ad1 commit 14a2f80
File tree
12 files changed
+850
-126
lines changed- posthog
- test
- ai/openai
12 files changed
+850
-126
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
1 | 6 | | |
2 | 7 | | |
3 | 8 | | |
| |||
194 | 199 | | |
195 | 200 | | |
196 | 201 | | |
| 202 | + | |
197 | 203 | | |
198 | 204 | | |
199 | 205 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| 7 | + | |
7 | 8 | | |
8 | 9 | | |
9 | 10 | | |
| |||
403 | 404 | | |
404 | 405 | | |
405 | 406 | | |
406 | | - | |
| 407 | + | |
407 | 408 | | |
408 | 409 | | |
409 | 410 | | |
| |||
446 | 447 | | |
447 | 448 | | |
448 | 449 | | |
449 | | - | |
| 450 | + | |
450 | 451 | | |
451 | 452 | | |
452 | 453 | | |
| |||
477 | 478 | | |
478 | 479 | | |
479 | 480 | | |
480 | | - | |
| 481 | + | |
481 | 482 | | |
482 | 483 | | |
483 | 484 | | |
| |||
519 | 520 | | |
520 | 521 | | |
521 | 522 | | |
522 | | - | |
| 523 | + | |
523 | 524 | | |
524 | 525 | | |
525 | 526 | | |
| |||
0 commit comments