GO Feature Flag provider for OpenFeature
Actively maintained. Last release 13 days ago, commits in 25 of the last 26 weeks. A safe choice.
pip install gofeatureflag-python-providerGO Feature Flag Python Provider
GO Feature Flag provider allows you to connect to your GO Feature Flag instance.
GO Feature Flag believes in simplicity and offers a simple and lightweight solution to use feature flags.
Our focus is to avoid any complex infrastructure work to use GO Feature Flag.
This is a complete feature flagging solution with the possibility to target only a group of users, use any types of flags, store your configuration in various location and advanced rollout functionality. You can also collect usage data of your flags and be notified of configuration changes.
Python SDK usage
Install dependencies
The first things we will do is install the Open Feature SDK and the GO Feature Flag provider.
pip install gofeatureflag-python-provider
Evaluation modes
The provider supports two evaluation modes:
| Mode | Description |
|---|---|
| In-Process (default) | Flag configuration is fetched and cached locally; evaluation runs via a WASM module — no per-evaluation network call. |
| Remote | Each flag evaluation makes an HTTP request to the GO Feature Flag relay proxy using the OFREP API. |
Initialize your Open Feature client
In-Process evaluation (default)
In-Process evaluation fetches the flag configuration from the relay proxy at startup and on a configurable polling interval. Flags are evaluated locally using a bundled WASM module, which gives you lower latency and no per-evaluation network dependency.
from gofeatureflag_python_provider.provider import GoFeatureFlagProvider
from gofeatureflag_python_provider.options import GoFeatureFlagOptions, EvaluationType
from openfeature import api
from openfeature.evaluation_context import EvaluationContext
goff_provider = GoFeatureFlagProvider(
options=GoFeatureFlagOptions(
endpoint="https://gofeatureflag.org/",
evaluation_type=EvaluationType.INPROCESS, # default
)
)
api.set_provider(goff_provider)
client = api.get_client(domain="test-client")
Remote evaluation
Remote evaluation sends each flag evaluation as an HTTP request to the relay proxy.
from gofeatureflag_python_provider.provider import GoFeatureFlagProvider
from gofeatureflag_python_provider.options import GoFeatureFlagOptions, EvaluationType
from openfeature import api
goff_provider = GoFeatureFlagProvider(
options=GoFeatureFlagOptions(
endpoint="https://gofeatureflag.org/",
evaluation_type=EvaluationType.REMOTE,
)
)
api.set_provider(goff_provider)
client = api.get_client(domain="test-client")