diff --git a/reflex/config.py b/reflex/config.py index 7aeea04b9..39f9b8485 100644 --- a/reflex/config.py +++ b/reflex/config.py @@ -474,9 +474,6 @@ class EnvironmentVariables: # Whether to run the frontend only. Exclusive with REFLEX_BACKEND_ONLY. REFLEX_FRONTEND_ONLY: EnvVar[bool] = env_var(False) - # Whether to send telemetry data to Reflex. - TELEMETRY_ENABLED: EnvVar[bool] = env_var(True) - # Reflex internal env to reload the config. RELOAD_CONFIG: EnvVar[bool] = env_var(False, internal=True) diff --git a/reflex/testing.py b/reflex/testing.py index 6e3fe8468..5afbec78d 100644 --- a/reflex/testing.py +++ b/reflex/testing.py @@ -252,7 +252,7 @@ class AppHarness: def _initialize_app(self): # disable telemetry reporting for tests - environment.TELEMETRY_ENABLED.set(False) + os.environ["TELEMETRY_ENABLED"] = "false" self.app_path.mkdir(parents=True, exist_ok=True) if self.app_source is not None: app_globals = self._get_globals_from_signature(self.app_source) diff --git a/tests/units/test_config.py b/tests/units/test_config.py index 64ea13e44..23181b389 100644 --- a/tests/units/test_config.py +++ b/tests/units/test_config.py @@ -40,8 +40,8 @@ def test_set_app_name(base_config_values): ("DB_URL", "postgresql://user:pass@localhost:5432/db"), ("REDIS_URL", "redis://localhost:6379"), ("TIMEOUT", 600), - (environment.TELEMETRY_ENABLED.name, False), - (environment.TELEMETRY_ENABLED.name, True), + ("TELEMETRY_ENABLED", False), + ("TELEMETRY_ENABLED", True), ], ) def test_update_from_env(