Skip to content

feat: opt in telemetry through fuelup#821

Open
kayagokalp wants to merge 6 commits intomasterfrom
kayagokalp/fuelupopt-in
Open

feat: opt in telemetry through fuelup#821
kayagokalp wants to merge 6 commits intomasterfrom
kayagokalp/fuelupopt-in

Conversation

@kayagokalp
Copy link
Copy Markdown
Contributor

Add telemetry opt-in for fuelup

This PR implements user consent for telemetry collection across all Fuel toolchain commands. Users are now prompted once to opt-in or opt-out of anonymous usage data collection.

What this enables

  • One-time telemetry consent prompt: Users are asked once (during install or first run) whether to enable telemetry
  • Works across all commands: Prompt appears for any fuelup-managed command (fuelup, forc, forc-fmt, etc.)
  • User control: fuelup telemetry enable/disable/status commands to change preference anytime
  • Proxy integration: The FUELUP_NO_TELEMETRY environment variable is set automatically based on user's choice before executing toolchain binaries
  • Non-interactive safe: Scripts and CI/CD automatically default to telemetry disabled without blocking

User experience

First-time users see:

Telemetry helps improve the Fuel toolchain by collecting anonymous usage data.
You can change this setting at any time by running:
  fuelup telemetry enable   # to enable telemetry
  fuelup telemetry disable  # to disable telemetry

Would you like to enable telemetry? (Y/n):

After opting in, telemetry events from forc and other tools are sent to InfluxDB (via the fuel-telemetry library). If opted out, FUELUP_NO_TELEMETRY=1 is set, disabling all telemetry.

@kayagokalp kayagokalp self-assigned this Feb 3, 2026
@kayagokalp kayagokalp force-pushed the kayagokalp/fuelupopt-in branch from 468ca0d to b8cc450 Compare February 3, 2026 06:30
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Feb 3, 2026

LCOV of commit 6c08cfd during CI #2311

Summary coverage rate:
  lines......: 84.4% (2567 of 3040 lines)
  functions..: 58.9% (385 of 654 functions)
  branches...: 64.9% (275 of 424 branches)

Files changed coverage rate: n/a

@kayagokalp kayagokalp marked this pull request as ready for review February 3, 2026 22:11
@cursor
Copy link
Copy Markdown

cursor bot commented Feb 3, 2026

PR Summary

Medium Risk
Touches the fuelup entrypoint, installer script, and proxy execution environment; mistakes could change behavior for all toolchain invocations or block automation despite non-interactive safeguards.

Overview
Introduces telemetry consent via a one-time prompt that persists the user’s choice in ~/.fuelup/.telemetry_opt_in, defaulting to disabled in non-interactive environments (added to both fuelup-init.sh and the Rust binary startup via prompt_telemetry_if_needed).

Adds a new fuelup telemetry subcommand (status|enable|disable) to view and manage the preference, and wires proxy execution to automatically set or remove FUELUP_NO_TELEMETRY based on the saved opt-in state before exec’ing toolchain binaries.

Written by Cursor Bugbot for commit 6c08cfd. This will update automatically on new commits. Configure here.

Comment thread fuelup-init.sh
Comment thread src/proxy_cli.rs
Copy link
Copy Markdown

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

Comment thread fuelup-init.sh
# Default to yes if user just presses enter
read -r answer </dev/tty
case $answer in
"n" | "N" | "no" | "No" | "NO")
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shell script missing case pattern for "nO" input

Low Severity

The case statement handling the telemetry prompt response explicitly enumerates case variations of "no" ("n" | "N" | "no" | "No" | "NO") but is missing "nO". If a user types nO, it falls through to the default * case and enables telemetry, contrary to the user's intent to decline. The Rust implementation handles this correctly by converting input to lowercase before matching.

Fix in Cursor Fix in Web

Copy link
Copy Markdown
Member

@JoshuaBatty JoshuaBatty left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants