Skip to content

docs(telemetry): opt out with the telemetry commands, not a text editor - #29976

Merged
wmadden-electric merged 2 commits into
mainfrom
docs/telemetry-use-the-commands
Aug 12, 2026
Merged

wmadden-electric merged 2 commits into
mainfrom
docs/telemetry-use-the-commands

Conversation

@wmadden-electric

@wmadden-electric wmadden-electric commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor

Linked issue

n/a — small docs change. Prompted by the engine-side telemetry work now underway; see the note at the end about what this PR deliberately does not pre-document.

At a glance

docs/Telemetry.md, "Flipping your choice", before:

To turn telemetry off (or back on), run prisma-next telemetry disable / prisma-next telemetry enable, or edit the file in any text editor and change the enableTelemetry value.

After:

To turn telemetry off (or back on), run prisma-next telemetry disable / prisma-next telemetry enable. The command writes the enableTelemetry value for you and the change takes effect on the next CLI invocation. prisma-next telemetry status reports what is in effect and why.

Decision

prisma-next telemetry enable | disable | status have been in the CLI the whole time. They exist so nobody has to open a JSON file to change their telemetry preference. The telemetry page was still teaching the JSON file as an equal route in three places — one of them told readers they could pre-create the file before ever running the CLI.

Hand-editing is now documented as what the file is, not as something you should do. The distinction the page holds throughout: describing the file is useful reference material; recommending that users write to it is not. telemetry status prints the file's path, so a reader who lands on it needs to know what the fields mean.

Nothing about where the file lives, what it contains, or how the fields resolve is removed.

How it fits together

  1. "The user-level config file" opens with one new sentence saying who writes it: the commands set the preference, status prints the resolved path, and the section that follows describes the contents so you can read them. The path bullets, the JSON samples, and the enableTelemetry / installationId field definitions are all untouched.
  2. Two field descriptions dropped their "…or a hand edit" parenthetical. They now say the CLI writes enableTelemetry when you make an explicit choice with enable / disable.
  3. "Flipping your choice" stops offering the text editor (shown above).
  4. "Fully resetting" no longer offers keep "enableTelemetry": false in it as an alternative to running disable.
  5. "The prisma-next telemetry command" now says plainly why it exists, and notes that enable / disable write the preference atomically and preserve every other field in the file — which is the concrete reason to prefer them over an editor.
  6. "2. The stored preference" keeps the JSON sample as what disable writes, and the paragraph telling readers to drop a pre-made config.json on disk is replaced. Provisioning a machine where the CLI has never run is a real need, and the environment variables already serve it — they work before any config file exists and suppress the first-run notice too.

The skills/prisma-8 quickstart carried the same hand-edit clause in its telemetry callout; it goes the same way, keeping the per-user vs. prisma-next.config.ts distinction it was making.

Reviewer notes

  • Nothing shipped-behaviour-facing moved. No filesystem path, no environment-variable name, no wording inside the verbatim first-run notice, and no prisma-next command prefix changed. Token counts for each of those are identical before and after; the only increase is prisma-next telemetry, which gains two mentions because the commands are now the route.
  • The first-run notice still mentions setting "enableTelemetry": false yourself. That block is quoted verbatim from the shipped binary and is left exactly as-is, so the page keeps matching what users actually see on stderr. The notice's wording is one of the things changing on the engine side.
  • Coming, and deliberately not written here: when this CLI ports onto the shared Prisma CLI engine, the config directory becomes prisma rather than prisma-next, the opt-out variable becomes PRISMA_DISABLE_TELEMETRY, and the first-run notice drops its hand-edit clause. None of that has shipped in the prisma-next CLI this page describes, so documenting it now would make the page wrong for the binary people are running. It lands with the port.
  • Anchors. One new intra-page link, pointing at #how-to-opt-out-or-back-in. It first pointed at the commands section's own slug, and lint:legacy-name was right to reject that: the rule allows a bare prisma-next only when the character after it is neither a word character nor a hyphen, and #the-prisma-next-telemetry-command is followed by -telemetry-command. That is also why the two command spellings in the same sentence pass. Every existing heading and anchor is unchanged, so #2-the-stored-preference and #1-environment-variables-runtime-only still resolve from their inbound links.
  • Second file. skills/prisma-8/references/quickstart.md is one sentence, included so the ruling isn't applied in only half the places a reader meets it. Easy to drop if you'd rather keep this to docs/Telemetry.md.

Testing performed

  • Docs-only change; no suites apply.
  • pnpm lint:legacy-name (node scripts/lint-legacy-name.mjs) — passes, on the exact tree pushed.
  • pnpm lint:docs (scripts/validate-package-readmes.mjs) — passes; its warnings are pre-existing and concern mongo package READMEs untouched here.
  • Verified every intra-page anchor in docs/Telemetry.md resolves to a heading that exists.
  • Diffed the frozen surfaces (config paths, PRISMA_NEXT_DISABLE_TELEMETRY, DO_NOT_TRACK, %APPDATA%, $XDG_CONFIG_HOME, prisma-next.config.ts, the notice block) against main: byte-identical.
  • The repo has no markdown linter or link checker in CI to run against docs/.

Skill update

skills/prisma-8/references/quickstart.md — the telemetry callout's opt-out routes now match the page. No CLI surface, flag, config field, or error code changed, so no other skill content is affected.

Checklist

Summary by CodeRabbit

  • Documentation
    • Clarified that telemetry preferences are managed through CLI commands rather than manual configuration edits.
    • Documented telemetry status behavior, preservation of unrelated settings, and default-on behavior.
    • Added guidance for resetting telemetry and installation identity by deleting the configuration.
    • Updated opt-out instructions to use the telemetry disable command or environment-variable settings for provisioning.

@wmadden-electric
wmadden-electric requested a review from a team as a code owner August 11, 2026 19:09
@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@coderabbitai

coderabbitai Bot commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: CHILL

Plan: Pro Plus

Run ID: ed0c6d9d-666e-4ac8-b3a8-685428ad47fe

📥 Commits

Reviewing files that changed from the base of the PR and between 4e78e5b and 7fb0150.

📒 Files selected for processing (1)
  • docs/Telemetry.md
🚧 Files skipped from review as they are similar to previous changes (1)
  • docs/Telemetry.md

📝 Walkthrough

Walkthrough

The documentation directs users to telemetry commands for preference changes. It describes user config ownership, command behavior, reset effects, installation identity preservation, and environment-variable opt-out guidance.

Changes

Telemetry documentation

Layer / File(s) Summary
Telemetry command contract and usage guidance
docs/Telemetry.md, skills/prisma-8/references/quickstart.md
The documentation states that the CLI manages the user config file. telemetry enable and telemetry disable persist explicit preferences. status reports the effective state without changing config or exposing the installation ID. The documentation also covers atomic preservation of unrelated fields, config deletion behavior, telemetry-command exemptions, and environment-variable opt-out guidance.

Estimated code review effort: 1 (Trivial) | ~5 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely summarizes the main documentation change: use telemetry commands instead of manually editing the configuration file.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/telemetry-use-the-commands

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

wmadden-electric added a commit to prisma/prisma-cli that referenced this pull request Aug 11, 2026
Section 3 required the config path and the environment variables to stay
put. The operator overruled that: the prisma-next naming goes everywhere,
with no fallback, no dual-write and no migration, because this is semver
zero and retiring that binary is the project's whole purpose.

The spec now states the two costs rather than leaving them implied. Every
stored preference and installation id at the old path is abandoned, so an
existing opt-out reverts to the default and the backend sees its population
turn over once; and the file stops being shared with the ORM's binary until
that one ports onto the engine. Both were weighed and accepted.

Also records that the first-run notice no longer offers hand-editing as an
opt-out route, and that prisma/prisma's telemetry page keeps the old names
until the binary it documents actually changes — the hand-editing half of
that ruling did not have to wait and is open as prisma/orm#29976.

Signed-off-by: willbot <[email protected]>
Signed-off-by: Will Madden <[email protected]>
@pkg-pr-new

pkg-pr-new Bot commented Aug 11, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

prisma-next

npm i https://pkg.pr.new/prisma-next@29976

@prisma/orm-extension-arktype-json

npm i https://pkg.pr.new/@prisma/orm-extension-arktype-json@29976

@prisma/orm-extension-middleware-cache

npm i https://pkg.pr.new/@prisma/orm-extension-middleware-cache@29976

@prisma/orm-extension-paradedb

npm i https://pkg.pr.new/@prisma/orm-extension-paradedb@29976

@prisma/orm-extension-pgvector

npm i https://pkg.pr.new/@prisma/orm-extension-pgvector@29976

@prisma/orm-extension-postgis

npm i https://pkg.pr.new/@prisma/orm-extension-postgis@29976

@prisma/orm-extension-supabase

npm i https://pkg.pr.new/@prisma/orm-extension-supabase@29976

@prisma/orm-family-mongo

npm i https://pkg.pr.new/@prisma/orm-family-mongo@29976

@prisma/orm-family-sql

npm i https://pkg.pr.new/@prisma/orm-family-sql@29976

@prisma/orm-framework

npm i https://pkg.pr.new/@prisma/orm-framework@29976

@prisma/orm-mongo

npm i https://pkg.pr.new/@prisma/orm-mongo@29976

@prisma/orm-postgres

npm i https://pkg.pr.new/@prisma/orm-postgres@29976

@prisma/orm-sqlite

npm i https://pkg.pr.new/@prisma/orm-sqlite@29976

@prisma/orm-target-mongo

npm i https://pkg.pr.new/@prisma/orm-target-mongo@29976

@prisma/orm-target-postgres

npm i https://pkg.pr.new/@prisma/orm-target-postgres@29976

@prisma/orm-target-sqlite

npm i https://pkg.pr.new/@prisma/orm-target-sqlite@29976

@prisma/orm-toolchain

npm i https://pkg.pr.new/@prisma/orm-toolchain@29976

commit: cd0b4d7

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 3

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@docs/Telemetry.md`:
- Around line 102-108: The Telemetry documentation should clarify the
installation ID lifecycle: update the first-run and reset descriptions so they
state that the first enabled command sending a telemetry event mints the ID,
unless the `telemetry enable` command has already created it.

In `@skills/prisma-8/references/quickstart.md`:
- Line 183: Update the telemetry paragraph around “Telemetry is opt-out” to
clarify that the one-time stderr notice and telemetry transmission occur only
for the first command that resolves telemetry as enabled and would send it,
including init. Exclude telemetry commands, disabled invocations, and CI
invocations from the claim that every command notifies and sends, while
preserving the existing opt-out configuration and documentation references.
- Line 183: Update the telemetry paragraph in the quickstart documentation to
replace the plain-text docs/Telemetry.md reference with a clickable Markdown
link targeting ../../../docs/Telemetry.md or the canonical published
documentation URL, while preserving the surrounding wording.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yml

Review profile: CHILL

Plan: Pro Plus

Run ID: 551dc15b-8e7e-46fc-bb0d-44bfca5742df

📥 Commits

Reviewing files that changed from the base of the PR and between 15308c6 and 4e78e5b.

📒 Files selected for processing (2)
  • docs/Telemetry.md
  • skills/prisma-8/references/quickstart.md

Comment thread docs/Telemetry.md Resolved
@github-actions

Copy link
Copy Markdown
Contributor

size-limit report 📦

Path Size
postgres / no-emit 170.11 KB (0%)
postgres / emit 147.84 KB (0%)
mongo / no-emit 100.41 KB (0%)
mongo / emit 90.25 KB (0%)
cf-worker / no-emit 194.31 KB (0%)
cf-worker / emit 169.66 KB (0%)

@wmadden
wmadden force-pushed the docs/telemetry-use-the-commands branch from 4e78e5b to 6138ad6 Compare August 11, 2026 19:18
…text editor

`prisma-next telemetry enable | disable | status` have existed the whole time.
docs/Telemetry.md still offered hand-editing config.json as an equal alternative
in three places, and told users they could pre-create the file before ever
running the CLI.

The file itself stays documented — where it lives, what the fields mean, what
`disable` writes into it — because `telemetry status` prints that path and
readers need to understand what they are looking at. What goes is the
instruction to write to it.

The pre-create-the-file case (fresh image, provisioning script, container
build) is now answered by the environment variables, which already work before
any config file exists.

The same hand-edit clause in the prisma-8 skill quickstart goes with it.

No path, environment-variable name, first-run notice wording, or command prefix
changed.

Signed-off-by: willbot <[email protected]>
Signed-off-by: Will Madden <[email protected]>
`lint:legacy-name` allows a bare `prisma-next` only when the character after it
is neither a word character nor a hyphen, which is why the two command
spellings in this sentence pass and the anchor slug
`#the-prisma-next-telemetry-command` did not.

Point the same sentence at "How to opt out (or back in)" instead — the parent
section of the commands, and a slug that carries no legacy name.

Signed-off-by: willbot <[email protected]>
Signed-off-by: Will Madden <[email protected]>
@wmadden
wmadden force-pushed the docs/telemetry-use-the-commands branch from 7fb0150 to cd0b4d7 Compare August 12, 2026 07:08
@wmadden-electric
wmadden-electric added this pull request to the merge queue Aug 12, 2026
Merged via the queue into main with commit e1f3787 Aug 12, 2026
17 checks passed
@wmadden-electric
wmadden-electric deleted the docs/telemetry-use-the-commands branch August 12, 2026 09:01
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.

3 participants