From 4b2c7bd849fabaa9b3ba87a87f6a94522f58b4c1 Mon Sep 17 00:00:00 2001 From: Jochen Seeber Date: Sat, 11 Apr 2026 21:20:23 +0200 Subject: [PATCH 1/2] Add env var to allow disabling usage reporting In the spirit of being nice and privacy-conscious, setting `SERENA_USAGE_REPORTING` to `false` will disable usage reporting. By default, usage reporting is enabled. --- src/serena/agent.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/serena/agent.py b/src/serena/agent.py index ab14239f..4174e0ae 100644 --- a/src/serena/agent.py +++ b/src/serena/agent.py @@ -410,10 +410,9 @@ class SerenaAgent: self._send_usage_info() def _send_usage_info(self) -> None: - is_ci = os.getenv("CI") == "true" or os.getenv("GITHUB_ACTIONS") == "true" - if is_ci: + if os.getenv("CI") == "true" or os.getenv("GITHUB_ACTIONS") == "true" or os.getenv("SERENA_USAGE_REPORTING") == "false": return - params = { + params: dict[str, str | int] = { "os": platform.system(), "dashboard": int(self.serena_config.web_dashboard), "version": self.version, From 3193637c751259ed36cbaa7138a1352d7a04676c Mon Sep 17 00:00:00 2001 From: Dominik Jain Date: Sun, 12 Apr 2026 15:01:55 +0200 Subject: [PATCH 2/2] Document environment variable for opting out of usage reporting --- CHANGELOG.md | 3 +++ docs/02-usage/050_configuration.md | 8 ++++++++ 2 files changed, 11 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index b8471139..7c5bf317 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,9 @@ Status of the `main` branch. Changes prior to the next official version change will appear here. +* General: + - Support environment variable `SERENA_USAGE_REPORTING` (set to `false` to disable usage reporting) + # 1.1.0 * General: diff --git a/docs/02-usage/050_configuration.md b/docs/02-usage/050_configuration.md index fe2b0d9e..404e8300 100644 --- a/docs/02-usage/050_configuration.md +++ b/docs/02-usage/050_configuration.md @@ -863,3 +863,11 @@ prompts: ``` It is advisable to use the default prompt as a starting point and modify it to suit your needs. + +### Usage Reporting + +On startup, Serena reports anonymous usage data to help us understand Serena usage. +Specifically, we collect the Serena version, the operating system & language backend being used as well as the dashboard enabled status. +No personally identifiable information or project-specific information is collected. + +If you want to opt out of usage reporting, set the environment variable `SERENA_USAGE_REPORTING` to `false`.