Skip to content

Conversation

@fioncat
Copy link

@fioncat fioncat commented Nov 19, 2025

Without this, launchdarkly will keep trying to send events to remote.

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines 33 to 37
"",
ldclient.Config{
DataSource: LaunchDarklyOfflineStore,
Offline: true,
},

Choose a reason for hiding this comment

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

P1 Badge Offline mode breaks offline datastore

Setting Offline: true in the no-API-key branch makes the LaunchDarkly server SDK run in offline mode, which causes every variation call to return the fallback value and bypass any configured data source. Our offline workflow relies on LaunchDarklyOfflineStore.Update(...) (see client_test.go lines 29‑35) to inject test flag values when no API key is present; with this flag turned on those values are never observed and the tests (and any offline usage) now always see the fallback. To stop event delivery without disabling the datastore we need a different configuration knob (e.g. disable the events component) instead of turning on global offline mode.

Useful? React with 👍 / 👎.

@jakubno
Copy link
Member

jakubno commented Nov 19, 2025

Hey @fioncat — thanks for opening this PR. The change makes sense, but we currently rely on overriding the default value in some tests, which isn’t possible with Offline set to true. If you can add a mock client that behaves correctly in tests, we’ll be able to accept the PR.

@jakubno jakubno self-assigned this Nov 19, 2025
@fioncat fioncat closed this Dec 10, 2025
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