feat: honor environmentId from EvaluationSeriesContext#13
Merged
Conversation
When TracingHookOptions::$environmentId is not configured, fall back to EvaluationSeriesContext::$environmentId — populated by the LaunchDarkly SDK from the X-Ld-Envid response header on polling fetches. Configuration still takes precedence when both are set. Removes the previous "options-only" limitation in the TracingHook docblock and corresponding "known gap" note in the test file. Adds two tests covering the series-context emission path and the precedence rule.
jsonbailey
approved these changes
Apr 27, 2026
keelerm84
added a commit
that referenced
this pull request
Apr 28, 2026
PR #13 wired TracingHook to fall back to EvaluationSeriesContext::$environmentId when no value is configured on TracingHookOptions, but the README still described that path as unsupported. - Update the environmentId option row to describe the precedence (option wins over series-context value). - Update the feature_flag.set.id "Emitted when" row to acknowledge both sources. - Drop the now-incorrect Known limitations entry; the addSpans casing note remains as the only limitation, demoted to a single paragraph.
keelerm84
added a commit
that referenced
this pull request
Apr 28, 2026
🤖 I have created a release *beep* *boop* --- ## 0.1.0 (2026-04-28) ### Features * add experimental addSpans option for per-evaluation spans ([#8](#8)) ([36b04e4](36b04e4)) * add optional feature_flag attributes (value, variationIndex, inExperiment) ([#6](#6)) ([5f43c4f](5f43c4f)) * add TracingHook with required feature_flag span event ([#5](#5)) ([1a3c016](1a3c016)) * add TracingHookOptions and attribute constants ([#4](#4)) ([ae33939](ae33939)) * emit feature_flag.set.id when environmentId is configured ([#7](#7)) ([26b6670](26b6670)) * honor environmentId from EvaluationSeriesContext ([#13](#13)) ([d761dcb](d761dcb)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Matthew Keeler <mkeeler@launchdarkly.com>
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.
When TracingHookOptions::$environmentId is not configured, fall back to
EvaluationSeriesContext::$environmentId — populated by the LaunchDarkly
SDK from the X-Ld-Envid response header on polling fetches. Configuration
still takes precedence when both are set.
Removes the previous "options-only" limitation in the TracingHook
docblock and corresponding "known gap" note in the test file. Adds two
tests covering the series-context emission path and the precedence rule.