Skip to content

docs(openspec): Propose restructure-cli-telemetry change - #33

Merged
thecodedrift merged 5 commits into
mainfrom
feat/rethink-posthog-telemetry
Jun 14, 2026
Merged

docs(openspec): Propose restructure-cli-telemetry change#33
thecodedrift merged 5 commits into
mainfrom
feat/rethink-posthog-telemetry

Conversation

@thecodedrift

@thecodedrift thecodedrift commented Jun 12, 2026

Copy link
Copy Markdown
Member

Base of the telemetry-rework stack — the OpenSpec change contract.

Reworks the CLI's PostHog taxonomy: a single cli_run denominator emitted once per invocation, cli_* reserved for concrete state transitions (cli_rule_created, cli_error, cli_check_completed, …), and cli_help { topic } replacing the help_* trio. Modifies the analytics capability; a hard cut with no dual-emit window.

Implementation lands in phased PRs stacked on top (cli_run → rule events → auth/lifecycle → cli_help → finalize+archive). See openspec/changes/restructure-cli-telemetry/.


Stack generated by Git Town

Establish the contract for reworking the CLI's PostHog taxonomy: a single
cli_run denominator emitted once per invocation, cli_* reserved for
concrete state transitions (cli_rule_created, cli_error, cli_check_completed,
...), and cli_help { topic } replacing the help_* trio. Modifies the
analytics capability; a hard cut with no dual-emit window.

Base of a stack; implementation lands in phased PRs on top.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings June 12, 2026 20:23

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Defines an OpenSpec change contract for a redesigned CLI telemetry taxonomy (PostHog), centered around a single cli_run denominator event per invocation and a smaller set of concrete cli_* state-transition events.

Changes:

  • Adds a new requirement for exactly one cli_run event per CLI invocation (emitted centrally).
  • Redefines the CLI analytics event taxonomy (hard cut) including cli_help { topic } and cli_error.
  • Adds proposal/design docs and OpenSpec metadata for the change package.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 8 comments.

File Description
openspec/changes/restructure-cli-telemetry/specs/analytics/spec.md Specifies the new telemetry event taxonomy and required properties/events.
openspec/changes/restructure-cli-telemetry/proposal.md Summarizes motivation, breaking change scope, and impacted areas for implementation PRs.
openspec/changes/restructure-cli-telemetry/design.md Records key design decisions (centralized cli_run, concrete transition events, hard cut).
openspec/changes/restructure-cli-telemetry/.openspec.yaml Declares the change package schema and created date.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread openspec/changes/restructure-cli-telemetry/specs/analytics/spec.md Outdated
Comment thread openspec/changes/restructure-cli-telemetry/specs/analytics/spec.md Outdated
Comment thread openspec/changes/restructure-cli-telemetry/specs/analytics/spec.md Outdated
Comment thread openspec/changes/restructure-cli-telemetry/specs/analytics/spec.md Outdated
Comment thread openspec/changes/restructure-cli-telemetry/specs/analytics/spec.md Outdated
Comment thread openspec/changes/restructure-cli-telemetry/proposal.md Outdated
Comment thread openspec/changes/restructure-cli-telemetry/proposal.md Outdated
Comment thread openspec/changes/restructure-cli-telemetry/design.md Outdated
Bring the stack-aware OpenSpec archive check (originally #31, landed in the
local-rule-routing stack) into the telemetry stack so PRs below the tip
show the check as skipped and only the tip runs it. Identical content to
the local-rule-routing copy, so the two stacks won't conflict when both
reach main.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
ci(openspec): Skip the archive check on non-tip stacked PRs

@thecodedrift thecodedrift left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

spec change already reviewed in depth, deferring to copilot review

thecodedrift and others added 2 commits June 13, 2026 10:58
PR #33 review:
- Drop cli_version from cli_run's property list across proposal/design/spec;
  the CLI version rides on the standard cliVersion property (no second field).
- Define cli_help's topic precisely: served topic, the literal "(index)" for
  no-arg, and the attempted topic for unknown; add an unknown-topic scenario.
- cliVersion is embedded at build time (no runtime read), matching the CLI spec.
- Clarify loggedIn vs anonymous as two distinct run-context dimensions, neither
  of which is the independent --anonymous flag.
- Align cli_check_completed counts on findings (matches the implementation).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Keep the proposed analytics spec/design prose in sync with the source
rename — the CLI acronym is uppercase in CLIError/CLIErrorCode.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@thecodedrift
thecodedrift merged commit 50cb031 into main Jun 14, 2026
3 checks passed
@thecodedrift
thecodedrift deleted the feat/rethink-posthog-telemetry branch June 14, 2026 04:42
@thecodedrift
thecodedrift restored the feat/rethink-posthog-telemetry branch June 14, 2026 04:44
@thecodedrift
thecodedrift deleted the feat/rethink-posthog-telemetry branch June 14, 2026 04:55
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