Skip to content

Commit 0cca57d

Browse files
authored
[ffe] fix provider initialization for python (#6969)
1 parent b6fabca commit 0cca57d

2 files changed

Lines changed: 10 additions & 1 deletion

File tree

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ jobs:
7878
library: ${{ matrix.library }}
7979
scenarios: ${{ needs.compute_libraries_and_scenarios.outputs.scenarios }}
8080
scenarios_groups: ${{ needs.compute_libraries_and_scenarios.outputs.scenarios_groups }}
81-
excluded_scenarios: OTEL_COLLECTOR_E2E${{ matrix.version == 'dev' && matrix.library == 'python' && ',FEATURE_FLAGGING_AND_EXPERIMENTATION' || '' }} # rely on real backend
81+
excluded_scenarios: OTEL_COLLECTOR_E2E # rely on real backend
8282
parametric_job_count: ${{ matrix.version == 'dev' && 2 || 1 }} # test both use cases
8383
skip_empty_scenarios: true
8484
display_summary: true

utils/_context/_scenarios/__init__.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -597,6 +597,15 @@ class _Scenarios:
597597
rc_api_enabled=True,
598598
weblog_env={
599599
"DD_EXPERIMENTAL_FLAGGING_PROVIDER_ENABLED": "true",
600+
# set_provider() in Python blocks until we receive RC
601+
# configuration for feature flags. But it is only sent
602+
# after weblog sucessfully boots and tests start
603+
# executing. Unfortunately, Python's OpenFeature SDK does
604+
# not have "set provider and don't wait," so we reduce the
605+
# timeout here, so that the provider initialization fails
606+
# fast, weblog boots, and provider recovers when we set RC
607+
# configuration later.
608+
"DD_EXPERIMENTAL_FLAGGING_PROVIDER_INITIALIZATION_TIMEOUT_MS": "100",
600609
"DD_REMOTE_CONFIG_POLL_INTERVAL_SECONDS": "0.2",
601610
"DD_METRICS_OTEL_ENABLED": "true",
602611
"OTEL_EXPORTER_OTLP_METRICS_PROTOCOL": "http/protobuf",

0 commit comments

Comments
 (0)