Skip to content

Conversation

@gustavohstrassburger
Copy link
Contributor

@gustavohstrassburger gustavohstrassburger commented Oct 24, 2025

Problem

PR #40260 introduced a bug as the payload from the feature flag is already a dict, not a json.

Changes

  • Changed from get_feature_flag_payload to get_feature_flag_result.

How did you test this code?

  • Manual

It was necessary to call this in the celery task, otherwise it didn't work.

        posthoganalytics.api_key = '<LOCAL_API_KEY>'
        posthoganalytics.disabled = False
        posthoganalytics.host = settings.SITE_URL

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 file reviewed, no comments

Edit Code Review Agent Settings | Greptile

Copy link
Contributor

@haacked haacked left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@github-project-automation github-project-automation bot moved this from In Review to Approved in Feature Flags Oct 24, 2025
gustavohstrassburger and others added 2 commits October 24, 2025 17:57
Changes the cohort chunking feature flag evaluation to use
get_feature_flag_result instead of get_feature_flag_payload to properly
check if the flag is enabled before accessing the payload. This prevents
attempting to read the payload when the flag is disabled.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <[email protected]>
@gustavohstrassburger gustavohstrassburger merged commit 9c5405c into master Oct 27, 2025
230 of 234 checks passed
@gustavohstrassburger gustavohstrassburger deleted the fix/cohort-calculation-chunking-flag-evaluation branch October 27, 2025 20:17
@github-project-automation github-project-automation bot moved this from Approved to Done in Feature Flags Oct 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants