feat(telemetry): CLI flow events#243
Open
LorrisSaintGenez wants to merge 5 commits into
Open
Conversation
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Up to standards ✅🟢 Issues
|
| Metric | Results |
|---|---|
| Complexity | 55 |
| Duplication | 35 |
TIP This summary will be updated as you push new changes.
…ogin Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <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
Foundations (#238)
Close()deferred inExecute()with a 3s timeout;NoOpTelemetryClientfallback on init failure.Trackwith custom properties + monotonicsequencecounter per invocation.events.go):Flow/Step/Direction/ErrorClassenums,FlowTracker, event name constants.Command Completedemitted before final flush; guard against orphan events whenPersistentPreRunEnever ran.Auth flow events (#239)
RunOAuthFlowemitsCLI Auth Started→ one terminal event (Completed/Aborted/Failed) withstep,duration_ms,error_class.Eventstruct + typed constructors + nil-safeTrackEvent(ctx, Event)helper.telemetrytest.RecordingClientfor flow event tests.Logout flow event (#242)
auth logoutemitsCLI Auth Logout(flow: logout) beforeClearToken().Identifyat logout.Application create + plan change flow events (#240)
application create:CLI Application Create Started→Completed/Aborted/Failedwithstep,region,plan,duration_ms,reason. Dry runs not tracked.application upgrade/downgrade:CLI Application Plan Change *withdirection,from_plan,to_plan.Abortedcarries areason(declined_terms/cancelled/billing_required/already_on_plan/no_candidates).Env header (#241)
X-Algolia-CLI-Env: prod(semver build) ordev(source build). Transport clones the request.//v1/batch).Test
GROUT-349
GROUT-351