feat: usage_data_opt_out also drops /report_event [Better data collection] - #53
Open
PetrDlouhy wants to merge 2 commits into
Open
feat: usage_data_opt_out also drops /report_event [Better data collection]#53PetrDlouhy wants to merge 2 commits into
PetrDlouhy wants to merge 2 commits into
Conversation
Telemetry is optional by definition: with the shared setting on, the route now answers 200 and forwards nothing, exactly like /report_usages. This puts the login funnel events under the same preference; anything the service itself needs must never ride this route. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The
usage_data_opt_outshared setting from #52 gated only/report_usages./report_event— the login-funnel telemetry, and the locked-asset event coming in Blendkit#2296's follow-up — bypassed the user's choice. Now both routes drop silently (200, nothing forwarded, no task) when the setting is on.The rule this encodes
Everything on
/report_eventand/report_usagesis optional by definition; anything the service itself needs must never ride these routes. Gating by route instead of per event name means there is no list to keep in sync and a reviewer can verify the boundary in one line. Documented in the route description (apispec, docs regenerated).Tests
TestReportEventHandlerDropsEventsWhenOptedOutmirrors the/report_usagestest: opt-out set in a temp settings store, handler returns 200, fake server receives nothing. Full suite,go vet,gofmtclean.Stacked on #52 (
claude/usage-report-route); merges after it.🤖 Generated with Claude Code