• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

supabase / cli / 25790264378

13 May 2026 09:22AM UTC coverage: 63.734% (-0.007%) from 63.741%
25790264378

push

github

web-flow
chore(cli/telemetry): clean up audited events (#5234)

## Summary
CLI telemetry audit cleanup from GROWTH-797. Removes one over-firing
`cli_upgrade_suggested` site, aligns the `cli_stack_started` capture
pattern with the rest of the codebase, and documents an early-return
invariant on `TrackUpgradeSuggested` so future audits don't misread the
SSO update flow as a double-fire.

## Changes
- `cli_upgrade_suggested` no longer fires on the read-only
`vanity-subdomains check` command (kept on `activate`, the actual gated
action). User still sees the billing-URL hint.
- `cli_stack_started` capture simplified to `_ =
phtelemetry.FromContext(ctx).Capture(...)`, matching `cmd/root.go`.
`Service.canSend()` already handles nil receivers.
- Comment on `internal/sso/update/update.go` PUT branch + docstring on
`TrackUpgradeSuggested` explaining that GET-fail and PUT-fail are
mutually exclusive via early-return, so at most one event fires per
command invocation. Deleting one site without the other undercounts
gated users.

## Testing
Tested locally in `apps/cli-go`:
- [x] `go test ./internal/login/... ./internal/telemetry/...
./internal/start/... ./internal/sso/... ./internal/vanity_subdomains/...
-count=1` — all pass.
- [x] `cli_stack_started` group/event assertion at
`internal/start/start_test.go:248-253` still passes after the nil-guard
removal.
- [x] `go vet ./...` and `go build ./...` clean.

Post-merge verification on PostHog:
- `cli_upgrade_suggested` volume on `feature_key = 'vanity_subdomain'`
should drop (was firing on both `check` and `activate`; now only
`activate`).

## Linear
- fixes GROWTH-797

---------

Co-authored-by: Andrew Valleteau <avallete@users.noreply.github.com>

9991 of 15676 relevant lines covered (63.73%)

7.06 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

66.09
/internal/debug/postgres.go


Source Not Available

The file "internal/debug/postgres.go" isn't available on github. Either it's been removed, or the repo root directory needs to be updated.

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc