← Back to Pull requests

docs(docs): error references are built from the release, and the CLI pages match rc.34 #8884

Closed
unknown closed this pull request without merging on Nov 20, 2026 14:04 UTC
View on GitHub
unknown unknown commented on Nov 20, 2026 11:26 UTC
Author

The Prisma ORM error reference documented a flag that no released CLI accepts:

--permit-policy-change

It also listed 11 error codes that 8.0.0-rc.24 never raises, and lacked 4 that it does raise. The cause: the page was generated from the main branch of prisma/orm, so it described code that had not been released.

Both error reference pages are now generated from the release. The generator asks npm for the latest version of @prisma/orm-postgres (for the ORM page) and prisma (for the CLI page), and builds from the git tag v<version> in prisma/orm and prisma/prisma-cli. Regenerated from v8.0.0-rc.24 and v8.0.0-rc.34, the ORM page loses the unreleased codes and the flag and gains the four missing codes.

This pull request also fixes the other findings on the CLI and skills pages from a full audit of the Prisma ORM 8 docs against prisma 8.0.0-rc.34.

The sync and the check

  • Sync (sync-error-reference-docs.yml, daily and on manual run). It resolves both releases from npm and confirms that each tag exists and that the npm package names the repository being checked out. If npm cannot be reached, the run fails; it never falls back to main. If a release is on npm but its tag does not exist yet, the run skips with a warning for the first 24 hours after publishing and fails after that, so pages that fall behind are noticed.

  • Check (error-reference-check.yml, on pull requests). It no longer depends on what latest is today. It reads the tag recorded in each committed page, regenerates the page from that tag, and fails on any difference. A new release therefore cannot break an unrelated pull request, and a page built from main is refused. It also runs the generator's tests (59, up from 39).

  • Values from step outputs and secrets reach shell scripts through env: only.
  • A release reaches the site with the next daily run, up to a day later. The existing dispatch from prisma-cli fires on pushes to its main, which no longer change the output; sending it from the release workflows of prisma/orm and prisma/prisma-cli, once the tag exists, would make the sync immediate. That is a change in those repositories and is not part of this pull request.

    Pages

  • cli/telemetry.mdx. New sections say what each event contains, when nothing is sent, and what the first-run notice says, taken from the CLI source and checked against a captured event. The page states that the value of the AI_AGENT environment variable is sent as it is set.

  • ai/tools/skills.mdx and cli/skills.mdx. The agents are claude, cursor, agents and devin; the page listed Codex and Windsurf. With npm, @prisma/composer arrives as a dependency of prisma, so a Prisma ORM project also gets the Composer skill.

  • cli/index.mdx. The "Adopt an existing database" steps wrote the inferred contract to a path the generated config does not read, so the contract emit that followed ignored it.

  • cli/init.mdx. init exits 2 for an invalid option and for a prisma.config.ts it cannot use, such as a Prisma ORM 7 config (CLI.CONFIG_MISSING_MARKER). A new section covers a package inside a monorepo.

  • cli/configuration.mdx. A bad formatter value fails with CLI.CONFIG_SECTION_INVALID; CLI.CONFIG_FIELD_INVALID arrives in the diagnostics.

  • cli/environment-variables.mdx, cli/orm-init.mdx, cli/global-flags.mdx, cli/feedback.mdx, cli/dev.mdx, cli/git.mdx: smaller corrections.
  • Not fixed here, because the fix is in another repository

  • The CLI error reference lacks 13 Composer codes (CONFIG.SECTION_MISSING and twelve DEV. codes). They need entries in docs/reference/error-reference.md in prisma/prisma-cli.

  • Three entries on the ORM page describe codes nothing raises (CLI.INIT_REINIT_NEEDS_FORCE, RUNTIME.EXECUTION_RESULT_MISSING, RUNTIME.MIDDLEWARE_RESULT_MISMATCH). The release's own source lists them.

  • A shared CLI. code raised by a Prisma ORM command carries a link to the ORM page, which has no entry for it. Both pages' introductions now say where such a code is documented.
  • How it was checked

    An implementer verified each finding before changing anything. A separate reviewer did a code review of the generator and workflows and a reader review of the pages, in two rounds; it broke the code to confirm the tests fail, and regenerated both pages from their recorded tags to confirm they equal the committed pages byte for byte. All findings are fixed except the upstream items above. The workflows have not run on GitHub Actions yet; their steps were run locally.

    Agent: gagarin-12
    🤖 Generated with Claude Code

    Diff: 588 lines (+441 / -147) across 7 files Reviewer: wmadden-electric Review duration: 157m
    All Vouch review confidence checks passed
    Residual risk 0.20 = Change Risk (0.50) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.50 · 588 lines diff across 7 files
    0.50
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.382
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #8884"
    general weight: 0.35
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 50.0% (MEDIUM) · Higher = larger blast radius
    50.0%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 19.7% · Safe to merge
    19.7%
    Repository