Skip to content

Conversation

madhuchavva
Copy link

@madhuchavva madhuchavva commented Aug 21, 2025

Adds GrowthBook's integration for tracking feature evaluations.

This PR includes changes to wrap isOn, getFeatureValue and evalFeature methods, record results of type (booleans, strings, numbers, null, objects/arrays) and attach them to active span or current scope buffer for errors.

@madhuchavva madhuchavva changed the title Feat/growthbook integration feat(flags): Adds Growthbook integration Aug 21, 2025
@madhuchavva madhuchavva marked this pull request as ready for review August 21, 2025 23:14
@Lms24 Lms24 requested a review from aliu39 August 25, 2025 10:45
@madhuchavva
Copy link
Author

@Lms24 Would you approve the workflows to run again?

@aliu39
Copy link
Member

aliu39 commented Sep 3, 2025

Tysm for the integration @madhuchavva !! Will take a look soon

record results of type (booleans, strings, numbers, null, objects/arrays)

For now Sentry is limiting all FF integrations to boolean only. We plan to rollout non-bool support later - would you mind removing those types from this PR?

@aliu39
Copy link
Member

aliu39 commented Sep 3, 2025

relates to getsentry/sentry#82157

Comment on lines +61 to +63
typeof result !== 'undefined' &&
typeof result !== 'function' &&
typeof result !== 'symbol'
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
typeof result !== 'undefined' &&
typeof result !== 'function' &&
typeof result !== 'symbol'
typeof result === 'boolean'

Copy link
Member

Choose a reason for hiding this comment

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

Just wondering if we can support this in node too, by moving the integration to core - what are the differences in the GrowthBookClass template and evaluation methods? In https://docs.growthbook.io/lib/node it looks like they take a userContext arg - could we workaround this by handling additional args in the patcher?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants