feat(cua-driver): anonymous telemetry properties — capture_mode, mcp_client, display_server#1976
feat(cua-driver): anonymous telemetry properties — capture_mode, mcp_client, display_server#1976f-trycua wants to merge 1 commit into
Conversation
…client, display_server
Enrich the entry-point telemetry events with three bounded, anonymous
(enum-only) properties via a new telemetry::entry_event_properties helper:
- capture_mode ("som"|"vision"|"ax") on cua_driver_mcp / cua_driver_serve,
read from the persisted ~/.cua-driver/config.json (default "som").
- mcp_client ("claude"|"codex"|"cursor"|"antigravity"|"openclaw"|
"opencode"|"hermes"|"pi"|"generic") on cua_driver_mcp_config, from
--client; unknown/unspecified collapse to "generic".
- display_server (Linux only; "wayland"|"x11"|"xwayland"|"unknown") on
all entry events, derived from the *type* of XDG_SESSION_TYPE /
WAYLAND_DISPLAY (never the value contents). Omitted on macOS/Windows.
All three are normalised to a fixed allow-list before reaching the
payload — no PII, no paths, no user-typed strings. No new keys or
endpoints; the existing public PostHog ingest key is unchanged.
Updates the privacy doc block in telemetry.rs and adds unit tests
asserting the bounded value sets.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01KMXCW4M5uK1HRGjjH4wueZ
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Linux visual regression artifactsMatrix jobs now run independently. Download visual artifacts from this workflow run.
|
Enriches the existing entry-point telemetry with three bounded, anonymous (enum-only) properties, built per command + platform by a new
telemetry::entry_event_properties(cmd)helper merged into the event payload.Properties added
capture_modecua_driver_mcp,cua_driver_serve"som"|"vision"|"ax"(read from~/.cua-driver/config.json, defaults to"som")mcp_clientcua_driver_mcp_config"claude"|"codex"|"cursor"|"antigravity"|"openclaw"|"opencode"|"hermes"|"pi"|"generic"(from--client; unknown/unspecified →"generic")display_server"wayland"|"x11"|"xwayland"|"unknown"(from the type ofXDG_SESSION_TYPE/WAYLAND_DISPLAY; omitted on macOS/Windows)Anonymity (no PII)
Every value is normalised to a fixed allow-list before it ever reaches the payload — never a path, command/tool arg, env value, or anything user-typed.
capture_modeandmcp_clientfall back to their safe default rather than emitting an unrecognised raw string.display_serverreads only the category of the session env, never the socket name/value. The default-envelope-wins merge semantics inbuild_payloadare preserved (the new keys don't collide).No secrets touched: no new keys or endpoints; the existing public PostHog ingest key is unchanged (public-ingest-only by design).
Tests / build
cargo build -p cua-driverandcargo test -p cua-driver --bin cua-driver telemetrypass (16 telemetry tests, 8 new) asserting the bounded value sets and per-command attachment. Updated the privacy doc block at the top oftelemetry.rs.Follow-up (out of scope here)
The
cua-driver mcpserver emits no per-tool telemetry (onlycua_driver_mcpat startup) — a known blind spot that needs a volume/sampling + crate-boundary design decision. Tracked in #1975.🤖 Generated with Claude Code
https://claude.ai/code/session_01KMXCW4M5uK1HRGjjH4wueZ