Repository navigation
feat: Add overrideAffected to the flag metadata - #44
Closed
kinyoklion wants to merge 1 commit into
Closed
kinyoklion wants to merge 1 commit into
kinyoklion wants to merge 1 commit into
Conversation
Co-Authored-By: Ryan Lamb <4955475+kinyoklion@users.noreply.github.com>
Contributor
|
I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requirements
Related issues
OpenFeature provider behavior spec (OFP) 1.1.0 added
overrideAffectedto the flag metadata table (Requirement 3.3.2), applying when the wrapped SDK supports flag overrides (OVERRIDE 1.6.1). Found during the weekly OpenFeature provider audit.Describe the solution you've provided
Evaluations whose LaunchDarkly reason is marked override-affected now carry
overrideAffected: truein the flag metadata. The key is omitted otherwise, the same wayinExperimentis handled.No released LaunchDarkly Ruby SDK has flag overrides yet.
EvaluationReason#override_affectedexists on the SDK'sfeat/overridesbranch (ruby-server-sdk #450, marked experimental). Therespond_to?guard means the provider keeps working with 8.19.x, where the key is never present, and picks up the indicator once an SDK with overrides is installed. Thelaunchdarkly-server-sdkrequirement is unchanged. The README flag metadata table lists the new key and says it needs an SDK version that has overrides.Describe alternatives you've considered
Waiting for the Ruby SDK release with overrides, then requiring that version. That would tie this provider release to the SDK release, and the guard costs one method check.
Additional context
Testing:
bundle exec rspec(77 examples) andbundle exec rubocopon Ruby 3.4 against 8.19.1. Specs stuboverride_affectedon a reason to cover true, false and absent. I also ran the converter against thefeat/overridesSDK branch:EvaluationReason.fallthrough.with_override_affected(true)produced{"variationIndex" => 0, "overrideAffected" => true}.Link to Devin session: https://app.devin.ai/sessions/afef6eb710c1429f878ab14b829c297a
Open in Devin Desktop: https://app.devin.ai/desktop/session/afef6eb710c1429f878ab14b829c297a?variant=devin