| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
feat: an application depends on one Prisma package (ADR 242) (#29864) ## What changes for someone using Prisma Today, an application that talks to Postgres installs a long list of our packages: ```jsonc { "dependencies": { "@prisma-next/postgres": "...", "@prisma-next/sql-runtime": "...", "@prisma-next/sql-orm-client": "...", "@prisma-next/target-postgres": "...", "@prisma-next/adapter-postgres": "...", "@prisma-next/sql-contract": "..." // ...a dozen more } } ``` After this PR, it installs one: ```jsonc { "dependencies": { "@prisma/orm-postgres": "0.16.0" } } ``` Everything else arrives as that package's own dependencies. Three of our example apps are converted in this PR to prove it — one per database — and each has exactly one Prisma package in its `dependencies`. This implements [ADR 242](https://github.com/prisma/prisma/pull/29852), which is already merged. ## What gets published 17 packages, all under the `@prisma` scope: - **3 database packages** — `@prisma/orm-postgres`, `orm-sqlite`, `orm-mongo`. An application installs exactly one. We call these *facades*: each is a small package that wires its database together and re-exports everything an application needs. - **6 extension packs** — PostGIS, pgvector, ParadeDB, Supabase, arktype-json, middleware-cache. Optional, installed alongside a database package. - **7 platform packages** — the framework, the toolchain, one per database family, one per database target. Applications never install these directly; they arrive as dependencies. Extension authors do install them. - **the `prisma` command**, as a bin-only package. Every other workspace package — around 50 of them — stops being published. They still exist in the repo as the unit we organise code in; they just stop having a life on the registry. **This PR does not make that switch yet.** It builds and proves the new surface while leaving today's publish list exactly as it is. Flipping it is a separate change. ## The problem this design has to avoid A published package can't depend on packages that won't exist on the registry. So each published package *contains a compiled copy* of the internal packages it covers. That creates a trap. If one application ends up with the same code twice — once inside a published package, once as its own package — then classes, registries, and anything compared by reference exist twice too. An `instanceof` check quietly returns false. Nothing crashes, nothing fails to compile, and both copies behave identically in isolation. You find out much later, somewhere unrelated. So the rule the whole design follows is: **every piece of internal code is published from exactly one package.** Concretely, that means: - Each published package is built in one pass, so code shared between its own entry points exists once. Verified from the build's source maps: no module appears in more than one chunk, in any published package. - When one published package needs code from another, it imports it as a real dependency rather than compiling in a second copy. - A facade re-exports from the platform packages; it never carries its own copy. `@prisma/orm-postgres/orm-client` and `@prisma/orm-family-sql/orm-client` are two names for the same object, and there's a test that asserts exactly that from installed tarballs. - One table in `packages/0-shared/publish-surface` maps every internal package to where it's published. The build, the code generator, and the lint checks all read it, so there's one answer to "where does this live" rather than three that can drift. ## Generated code follows the application Prisma writes imports into your project — contract types and migration files. Those imports have to name packages your project actually depends on, or they won't resolve. So the generator now reads the `package.json` next to the config it's generating for. A project that depends on `@prisma/orm-postgres` gets imports from that package. A project on today's names keeps today's names. Nothing to configure, because the manifest already says which it is. Contract hashes are unaffected, and that isn't an assumption — hashes are computed from a structure that import text never enters, and there's a test asserting the hash is identical across naming schemes *while* the emitted imports demonstrably differ. ## What stops the trap coming back Two checks, because the failure is silent and won't show up in a test suite: - Every example app and test project must use one naming scheme, not a mix. `lint-single-import-root` scans them and fails the build if any project imports from both, since that's the situation that loads code twice. - `lint-consumer-internal-imports` counts how many internal-package imports remain in those projects and compares against a committed number. It fails if the number goes up (someone added one) and also if it goes down without the number being updated (so improvements get locked in). Target is zero. The build itself also refuses to proceed if the published-package map would put one module in two places, or if a published package's `package.json` no longer matches what its code actually needs. ## Reading this PR It's large — 257 files — because it's a migration. The commits are grouped and meant to be read in order: 1. **Platform packages** — the build mechanism, and the seven platform packages it produces. 2. **Database packages, extension packs, the `prisma` command** — completes the set of 17. 3. **Generated imports become configurable** — one place decides which names get written, with today's names still the default. 4. **Database-family symmetry, publishing the map, the identity checks.** 5. **One package per application** — the three converted examples, the re-exports they proved necessary, and the counting check. 6. **Migration files follow the project too.** One thing worth knowing while reading: re-exporting a package republishes all of its sub-paths, not just the one that was needed. This PR adds 115 published sub-paths across the three database packages. Two candidates were dropped for exactly that reason — see below. ## Alternatives considered **Let an application install platform packages alongside its facade.** Nothing would need re-exporting and the facades would stay thinner. Rejected: an application would again juggle several Prisma dependencies whose correct combination it maintains by hand, and getting it wrong — upgrading one and not the other — produces the silent two-copies failure above. Re-exporting costs a generated line and nothing at runtime. **Re-export everything an application might plausibly want.** Rejected in review: because re-exporting brings a package's entire sub-path surface, generosity is expensive and hard to undo. Migration tooling (54 sub-paths) was dropped because its only users are extension packs, which install platform packages anyway; the SQL driver re-export was dropped because nothing imported it at all. What remains is what a converted example actually needed. **Flip the publish list in this same PR.** Rejected: it would mix "does the new surface work" with "is it safe to stop publishing 50 packages" in one review. The switch is mechanical once this lands, and gets its own change. ## Verification `build`, `typecheck` (156 tasks), `test:packages` (1077 files / 14087 tests), `test:e2e`, `lint`, `lint:deps`, `lint:docs`, `lint:manifests`, `check:publish-deps`, `check:clean-tree`, `lint:casts` and `lint:throws` (no new instances), `test:scripts`, coverage, the tarball-install suites, and regenerating every committed artifact leaves the tree unchanged. Known-unstable and unrelated to this change: the `relation-mode-gh-*` port suites (TML-3140), and several test timeouts that are too tight under load. ## Follow-ups TML-3124 switch the publish list · TML-3127 build cache can validate a stale published package on CI · TML-3140 unstable port suites · TML-3141 a test-helper sub-path reaches a package that is never published. 🤖 Generated with [Claude Code](https://claude.com/claude-code) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Added consolidated public ORM packages for PostgreSQL, MongoDB, SQLite, framework tooling, database targets, and extensions. - Generated contracts, migrations, and scaffolds now adapt imports to the consuming project’s package surface. - Added facade-provided `prisma-next` CLI access and consolidated migration entrypoints. - **Documentation** - Updated installation, package naming, public entrypoint, and migration scaffolding guidance. - **Tests** - Added coverage for package installation, exports, CLI behavior, module identity, and import compatibility. - **Chores** - Added checks preventing incompatible internal and public package imports. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Signed-off-by: willbot <w.a.madden+machine@gmail.com> Signed-off-by: Will Madden <madden@prisma.io> Co-authored-by: Claude Fable 5 <noreply@anthropic.com> | 1 个月前 | |
feat: implement CLI telemetry Implements Phase 1 CLI telemetry for Prisma Next: an explicit opt-in consent path in `prisma-next init`, a detached sender process that posts anonymous command-start events without blocking CLI work, and a Bun/Postgres backend that stores accepted events through Prisma Next itself. Deliberately out of scope: crash/error reporting. That path has different privacy and lifecycle constraints and is deferred to a separate Phase 2. ## At a glance ```ts const payload: ParentToSenderPayload = { installationId: config.installationId, version: inputs.version, command: sanitised.command, flags: sanitised.flags, databaseTarget: inputs.databaseTarget, extensions: inputs.extensions, projectRoot: inputs.projectRoot, endpoint: resolveTelemetryEndpoint(env), }; ``` Telemetry starts from a sanitized parent-process payload — command and flag names only, no positional args or flag values — and a detached child enriches and sends it. ## How it fits together - **Backend storage is contract-first.** `apps/telemetry-backend/src/prisma/contract.prisma` defines a single `TelemetryEvent` model, with committed `contract.json` / `contract.d.ts` artifacts and migration outputs so the ingest service dogfoods Prisma Next. - **The ingest API is small and forward-compatible.** `POST /events` requires the stable core fields, defaults omitted optional fields to `null` / `[]`, drops unknown future keys, enforces request-size limits, and rate-limits callers before INSERT. - **User consent is per-user and default-off.** `@prisma-next/cli-telemetry` stores `enableTelemetry` and a random v4 `installationId` under the user config directory; env overrides and CI suppress telemetry without mutating that file. - **The CLI fires at command start.** A `preAction` hook resolves CI/env/user gates first, then loads only the telemetry-safe pieces of project config, sanitizes Commander metadata, and forks a detached sender. - **The child owns all I/O.** The sender enriches the payload with runtime, package manager, TypeScript version, OS/arch, and best-effort agent markers, POSTs with a hard timeout, and exits 0 while swallowing failures. ## Behavior changes Adds the telemetry backend ingest service. Accepts `POST /events`, validates the payload, enforces 32 KiB request limits and per-IP rate limiting, then inserts via Prisma Next. - Implementation: `apps/telemetry-backend/src/handler.ts`, `apps/telemetry-backend/src/schema.ts`, `apps/telemetry-backend/src/rate-limiter.ts` - Tests: `apps/telemetry-backend/test/handler.test.ts`, `apps/telemetry-backend/test/rate-limit.handler.test.ts` Adds default-off, opt-in telemetry consent. `init` asks a final interactive consent question only when prompting is allowed, `--yes` is not auto-accepting, CI/env overrides are absent, and no stored answer exists. - Implementation: `packages/1-framework/3-tooling/cli/src/commands/init/inputs.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/user-config.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/gating.ts` - Tests: `packages/1-framework/3-tooling/cli/test/commands/init/consent-prompt.test.ts`, `packages/1-framework/3-tooling/cli-telemetry/test/gating.test.ts` Adds detached command-start delivery. The CLI preAction hook forks the sender, disconnects/unrefs it, and keeps telemetry failures out of the parent command's stdout/stderr and exit path. - Implementation: `packages/1-framework/3-tooling/cli/src/cli.ts`, `packages/1-framework/3-tooling/cli/src/utils/telemetry.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/spawn.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/sender.ts` - Tests: `packages/1-framework/3-tooling/cli/test/utils/telemetry.test.ts`, `packages/1-framework/3-tooling/cli-telemetry/test/spawn.test.ts`, `packages/1-framework/3-tooling/cli-telemetry/test/integration.test.ts` Adds sanitization and enrichment without user values. Events include command name, user-supplied long flag names, runtime/package metadata, target, extensions, and agent markers; they intentionally exclude positionals and flag values. - Implementation: `packages/1-framework/3-tooling/cli-telemetry/src/sanitize.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/enrich.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/detect-agent.ts` - Tests: `packages/1-framework/3-tooling/cli-telemetry/test/sanitize.test.ts`, `packages/1-framework/3-tooling/cli-telemetry/test/enrich.test.ts`, `packages/1-framework/3-tooling/cli-telemetry/test/detect-agent.test.ts` ## Compatibility, migration, risk - Telemetry remains off unless the user explicitly opts in; `PRISMA_NEXT_DISABLE_TELEMETRY`, `DO_NOT_TRACK=1`, and CI all suppress it. - The backend wire format is backward-compatible for optional fields and forward-compatible for unknown future fields. - `apps/*` is now part of the workspace, so the telemetry backend participates in install/build/test orchestration. Existing package-layer dependency checks remain scoped to `packages/`. - The production endpoint URL is currently a build-time constant; if Prisma Compute reassigns it, the client constant needs to be updated before release. ## Alternatives considered - **Send telemetry synchronously from the parent process.** Rejected because network failures or slow DNS could affect the CLI UX. - **Use a per-project telemetry setting.** Rejected because one developer's project config should not enroll or opt out teammates. - **Collect crash/error reporting in Phase 1.** Rejected because stack traces and failure lifecycle need separate consent and sanitization rules. Refs TML-2557 Co-authored-by: Alexey Orlenko <alex@aqrln.net> Signed-off-by: Alexey Orlenko <alex@aqrln.net> Signed-off-by: Alexey Orlenko's AI Agent <robot@aqrln.net> | 3 个月前 | |
refactor: rename every user-facing prisma-next identifier to Prisma 8 (#30262) ## Linked issue n/a — no Linear ticket. Completes the rename that #30248 started for prose; builds on #30261. ## At a glance Every `prisma-next` identifier a user can see is renamed. Before and after, for a scaffolded project: ```text // use prisma-next → // use prisma-8 (schema header) prisma-next.md → prisma-8.md (primer at the project root) PRISMA_NEXT_DISABLE_TELEMETRY → PRISMA_DISABLE_TELEMETRY (and every other PRISMA_NEXT_* variable) ~/.config/prisma-next/ → ~/.config/prisma-8/ (per-user telemetry config) prisma-next contract emit → prisma contract emit (CLI invocations in docs, fixtures, recordings) ``` ## Summary After #30248 the product was called Prisma 8 in prose, but the working name was still written into user projects and printed by the CLI: the schema header, the primer file, the environment variables, the per-user config directory, the language-server diagnostic source, the Standard Schema vendor string, the contract brand symbol, the advisory-lock domain, and about 650 fixture and doc files that spelled out `prisma-next …` commands. This PR renames all of it in one pass and tightens the legacy-name lint so the only occurrences left are the ones with a reason. ## Decision One commit. The mapping: | Surface | Before | After | |---|---|---| | Schema header | `// use prisma-next` | `// use prisma-8` | | Primer file `init` writes | `prisma-next.md` | `prisma-8.md` | | CLI environment variables | `PRISMA_NEXT_*` | `PRISMA_*` | | Per-user config directory | `prisma-next/` | `prisma-8/` | | Language-server diagnostic source | `prisma-next` | `prisma` | | Standard Schema vendor, VS Code publisher | `prisma-next` | `prisma` | | Contract brand symbol | `__prisma_next_brand__` | `__prisma_8_brand__` | | Postgres advisory-lock domain | `prisma_next.contract.marker` | `prisma_8.contract.marker` | | Example database names | `prisma_next_*` | `prisma_8_*` | | README banner image | `images/prisma-next.png` | `images/prisma-8.png` | | Telemetry docs URL | `prisma-next.dev/docs/…` | `www.prisma.io/docs/…` | | New-issue links | `github.com/prisma/prisma-next/issues/new` | `github.com/prisma/orm/issues/new` | | CLI invocations in prose, fixtures, and recordings | `prisma-next db verify` | `prisma db verify` | `prisma-8` is the slug the repo already uses for the skill, the examples, and the upgrade directories, so it is the slug for everything that needs one. Environment variables drop the infix entirely because `PRISMA_*` is what users expect and nothing else in the repo claims those names. What keeps the old name, each with a lint allowance that says why: - **Dated records**: changelog, release notes, ADRs, shipped upgrade instructions, gotcha logs, the framework-gaps review, and the `projects/` and `drive/` write-ups. - **Pinned links** into the old repository by number, Linear slugs, and links to ADRs whose filenames carry the name. - **`@cipherstash/prisma-next`**, a third party's published package name. - **Retirement proofs**: the list of old skill directories `init` deletes, and the tests asserting that no `prisma-next` bin or skill directory is installed any more. ## Behavior changes & evidence - **Schema header.** The inferred-schema printer and the `init` templates write `// use prisma-8`. The language server accepts both headers, so existing schemas keep their diagnostics and completion, and its Format action rewrites the old header to the new one. [packages/1-framework/3-tooling/language-server/src/schema-directive.ts](packages/1-framework/3-tooling/language-server/src/schema-directive.ts), [packages/1-framework/2-authoring/psl-printer/src/ast-to-print-document.ts](packages/1-framework/2-authoring/psl-printer/src/ast-to-print-document.ts). Evidence: the `renameLegacyDirective` tests, the server test that formats a legacy-headed schema, and the psl-printer tests. - **Environment variables.** Telemetry gating, the endpoint override, and the debug switch read the new names. `PRISMA_NEXT_DISABLE_TELEMETRY` is still honoured as an opt-out so nobody is silently opted back in; the endpoint and debug spellings are not. [packages/1-framework/3-tooling/cli-telemetry/src/gating.ts](packages/1-framework/3-tooling/cli-telemetry/src/gating.ts). Evidence: cli-telemetry gating tests. - **Per-user config directory.** [packages/1-framework/3-tooling/cli-telemetry/src/user-config.ts](packages/1-framework/3-tooling/cli-telemetry/src/user-config.ts). Existing users see the telemetry consent prompt once more; nothing else is lost. - **Primer file.** [packages/1-framework/3-tooling/cli/src/orm/init-scaffold.ts](packages/1-framework/3-tooling/cli/src/orm/init-scaffold.ts). Evidence: init-scaffold tests and template snapshots. - **Advisory-lock domain.** A CLI on this version and one on the previous version take different locks for the same marker. Both versions running migrations against one database at the same moment is already unsupported. - **Upgrade instructions.** Entries for the header, the environment variables, and the primer file are recorded in the rc.9 → rc.10 app and extension instructions with detection patterns, so the published upgrade skill applies the rename. ## Testing performed - `pnpm test` in cli (1437), cli-telemetry (112), language-server (312), psl-printer (63), framework-components (672), target-postgres (1607), vite-plugin-contract-emit (31), emitter (231), and `pnpm test:scripts` (507): all pass after `pnpm build`. The language-server tests hard-coded the old header's length in semantic-token arrays and span offsets; those expectations are updated. - Committed migration steps and their content-addressed contract snapshots are left untouched, since rewriting them would break their hashes; the lint treats them as dated records. - `pnpm lint:legacy-name` passes with the tightened allowances; `node --test scripts/lint-legacy-name.test.mjs` passes (14 tests, including new negative cases for the header, primer, and skill names). - `pnpm check:upgrade-coverage --mode pr --prev origin/main` passes. ## Skill update `skills/prisma-8` references and the two rc.9 → rc.10 upgrade instruction files are updated in this PR. ## Checklist - [x] All commits are signed off (`git commit -s`) per the [DCO](../CONTRIBUTING.md#developer-certificate-of-origin-dco). - [x] I read [CONTRIBUTING.md](../CONTRIBUTING.md) and the change is scoped to one logical concern. - [x] Tests are updated. - [ ] The PR title is in `TML-NNNN: <sentence-case title>` form. No Linear ticket exists for this change. - [x] The **Skill update** section above is filled in. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Signed-off-by: willbot <w.a.madden+machine@gmail.com> Signed-off-by: Will Madden <madden@prisma.io> Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com> | 3 天前 | |
feat(cli)!: stop publishing the prisma-next CLI — the unified prisma-cli replaces it (#30005) ## At a glance Before this PR, a Prisma Next user installed `prisma-next` from npm and their project looked like this: ```bash prisma-next db update ``` ```ts // prisma-next.config.ts import { defineConfig } from '@prisma/orm-postgres/config'; export default defineConfig({ contract: './contract.ts', output: './generated', }); ``` After this PR, this repo publishes no CLI binary at all. Users install `@prisma/cli@next` (the unified Prisma CLI, built in the prisma-cli repo) and run: ```bash prisma-cli db update ``` ```ts // prisma.config.ts import { defineConfig } from '@prisma/cli-engine'; import { defineConfig as ormConfig } from '@prisma/orm-postgres/config'; export default defineConfig({ orm: ormConfig({ contract: './contract.ts', output: './generated', }), }); ``` Same commands, same behaviour — the ORM commands this repo builds are mounted into the unified CLI as its `orm` command family. ## The decision Stop publishing a CLI from this repo, and delete the command-line shell that made publishing one possible. Some context for anyone who hasn't followed the port series: the ORM CLI used to be a commander program in this repo — commander parsed the flags, per-command renderers wrote styled output to stdout, and a `handleResult()` helper mapped results to exit codes. Over the previous PRs, every command was re-implemented as a command definition for `@prisma/cli-engine`, the shared CLI framework that the unified `prisma-cli` binary is built on. The engine parses arguments, prints help, renders each command's result envelope, and owns the exit code. That left the commander shell and the published `prisma-next` bin as duplicates of things the engine and the unified CLI already do. This PR removes both. The one deliberate survivor is the migration-file runtime: user-authored `migration.ts` files execute through their own small clipanion CLI (`MigrationCLI.run`) with a 0/1/2 exit scheme. That is a public contract of authored migrations, not part of the shell, so it stays — and a dedicated test now pins the exit scheme so the cutover cannot silently change it. ## What the PR does, step by step **1. The published bin goes away; a workspace-local bin stays.** `packages/9-public/prisma-next` (the bin-only shim package from ADRs 211/242) is deleted, and the public facade packages no longer declare launcher bins. `@internal/cli` keeps a workspace-local `prisma-next` bin pointing at `dist/bin.mjs` — a thin engine entry (`runOrmCli(process)`) that mounts the same 22 command paths the unified CLI mounts — so the repo's examples, dev flows, and spawn smoke tests keep working without a published package. The "install the CLI" journey now belongs to the unified CLI. **2. The commander shell is deleted.** Every command runs as an engine definition under `src/orm/`. Commander, the renderers, `handleResult`, the global-flag resolver, the shutdown handler, and the help formatter are gone; the engine provides all of it. **3. The legacy tests are re-expressed on the engine harness.** Commander-era tests asserted styled stdout, which no longer exists here. They were ported to `createTestCli`, the in-process engine harness, asserting data: the settled result envelope, emitted events, and the exit code — no stdout parsing, no snapshots. Pure formatting tests became presentation-model data assertions or were deleted with a per-file reason recorded in the porting ledger (a legacy test could only be deleted when the behaviour died with the shell or an engine test with the same name covers it). One suite, `cli.bin-smoke.e2e.test.ts`, still spawns the real bin to pin startup, dispatch, exit-code surfacing, and the telemetry sender spawn. **4. Config consolidates on `prisma.config.ts`, with a deprecation path.** The unified CLI reads `prisma.config.ts` in the nested shape shown above (`defineConfig({ orm: ormConfig({ … }) })` from `@prisma/cli-engine`). All 226 config files in this repo were renamed and rewrapped. The loader prefers the new filename and shape, and still accepts the old `prisma-next.config.*` filename and the old flat shape, each with a stderr deprecation warning (`CONFIG.DEPRECATED_FILENAME`, `CONFIG.DEPRECATED_SHAPE`), so existing projects keep loading until the codemod story lands. The bin adapter unwraps the `orm` section before handing config to command handlers, so the handlers are untouched. **5. `init` scaffolds for the unified CLI.** New projects get `prisma.config.ts` in the engine shape, package scripts that invoke `prisma-cli`, and devDependencies `@prisma/cli@next` + `@prisma/cli-engine` (the config file imports the engine's `defineConfig`). **6. User-facing prose names the bin users actually have.** The engine only substitutes its `{bin}` placeholder in help examples and command redirects, so ~100 hardcoded `prisma-next <cmd>` strings in next-actions, fix suggestions, and init templates now say `prisma-cli`. Telemetry threads the settled exit code through the pipeline. The framework-vocabulary ratchet drops 364 → 308. **7. Docs catch up.** The root README installs `@prisma/cli@next`; the CLI package README describes the engine entry; the style guide, error reference, and e2e-patterns doc describe commander in the past tense; ADR 242 carries a supersession note for the retired bin distribution; ADR 239 records the `CLI.*` error namespace as shared with `@prisma/cli-engine`. ## Operator-review items - **`init`'s devDependency choice**: `@prisma/cli@next` + `@prisma/cli-engine`, scripts on the `prisma-cli` bin. The alternative — the `prisma-next` npm name living on as an rc channel published from the prisma-cli repo — does not exist yet; scaffolding it today would install the stale artifact this repo used to publish. - **The npm `prisma-next` name**: this PR only stops publishing it; deprecating or handing off the name is operator-owned. - **Generated-artifact headers**: emitted artifacts still carry `prisma-next`-flavoured headers. The emitter cannot know which bin invoked it, and changing the header would churn every committed fixture, so they were left alone — flagging for an explicit call. - **Hardcoded `prisma-cli` in remediation strings**: the ~100 next-action/fix strings name the unified bin literally because the engine has no `{bin}` templating outside help/redirects. If the engine grows that affordance, these should switch to it. ## Verification | Check | Result | | --- | --- | | root `pnpm build` | exit 0 | | cli `pnpm typecheck` / `pnpm lint` / `pnpm test` | exit 0 / exit 0 (264 infos) / 113 files, 1410/1410 | | config-loader `pnpm test` | exit 0 — 53/53 | | `pnpm test:integration` (full) | 10 failed files on the loaded full run → triaged: 1 real (a retry-hint assertion behind the prose sweep — fixed), the known machine-local timezone artifact (`issues-28192-pg-historical-dates`, 2 tests), a mongodb-memory-server port collision, and 7 timeout flakes; everything except the timezone artifact passes isolated with `TEST_TIMEOUT_MULTIPLIER=2` (34/34 + 2/2) | | `pnpm fixtures:check` | exit 0, no fixture diffs (after repairing the two cutover leftovers it caught — see the last commit) | | `pnpm lint:deps` | exit 0 | | `node scripts/lint-framework-vocabulary.mjs` | exit 0 (count 308 = threshold) | The cutover's divergence record and porting ledger live in the prisma-cli repo on branch `s5-cutover-divergences` (`.drive/projects/prisma-cli-v8/assets/s2/parity-divergences-s5-cutover.md`, `assets/s5/cutover-ledger.md`). ## Alternatives considered - **Keep publishing `prisma-next` as a thin shim over the engine bin.** Rejected: it would ship a second binary with identical behaviour under a stale name, while the rollout plan's happy path is the unified CLI. - **Port the stdout-formatting tests onto the engine renderer instead of deleting them.** Rejected: the renderer belongs to the engine and is tested there; re-asserting its output here would pin another repo's presentation. - **A hard cut on config filenames — engine semantics only, no fallback.** Rejected for this repo's own users: the deprecation path keeps every existing project loading (with a warning) until the codemod story lands post-rc. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Signed-off-by: willbot <w.a.madden+machine@gmail.com> Signed-off-by: Will Madden <madden@prisma.io> Co-authored-by: Claude Fable 5 <noreply@anthropic.com> | 1 个月前 | |
docs: rewrite README for Prisma 8, fix orm init dist-tag, sweep "Prisma Next" prose (#30248) ## Linked issue n/a — no Linear ticket. Follow-up to the README banner swap in #30225. ## At a glance The README's getting-started commands, before and after, checked against [prisma.io/docs/getting-started](https://www.prisma.io/docs/getting-started): ```bash # before npm create prisma@next npx @prisma/cli@next orm init # after npm create prisma npx prisma orm init npx prisma skills sync ``` The `prisma` package has no `next` dist-tag any more (`latest` is `8.0.0-rc.13`, `prev` is `7.10.0`), so the old commands no longer resolve. ## Summary The README still introduced the product as "Prisma Next" in Early Access, pointed at the removed `next` dist-tag, listed extensions by their `@internal/*` workspace names, and linked to `prisma/prisma`. The rest of the repo had about a thousand prose mentions of the working name. This PR fixes all of it and one real bug the sweep turned up. ## Decision Five commits, each reviewable on its own (the fifth only records the sweep against the in-flight upgrade-instruction files for the coverage check): 1. **Rewrite the README against the live docs.** Every instruction in it now matches the getting-started, quickstart, `orm init`, `skills`, and extensions pages in prisma/web. 2. **Fix `orm init` to install `prisma@latest`.** The CLI added `prisma@next` as a dev dependency. That tag no longer exists on npm, so `orm init` fails at the install step for anyone running it today. The engine fallback moves from `@prisma/cli-engine@next` (0.2.3, stale) to `@latest` (0.3.0). 3. **Replace "Prisma Next" with "Prisma 8" in prose repo-wide.** Docs, doc comments, READMEs, package descriptions, skill references, and user-facing strings. 4. **Carry the pnpm trust-policy exemptions into the tarball smoke tests.** The scratch installs those tests run trip a trust-downgrade check on `undici-types@6.21.0` (no provenance, while 6.13.0 and 6.18.2 had it). The repo already exempts it for the workspace install; the test kit now restates `trustPolicy` and `trustPolicyExclude` in the scratch project the way it restates the release-age settings. Reproduced on main with a fresh metadata cache, so this is a pre-existing failure that any run without cached metadata hits. ## Reviewer notes - **Rebased on #30229.** That PR's release-candidate banner and its `scorecard.md` link replace the roadmap reference in the README, and `ROADMAP.md` stays deleted. The prose sweep re-applied cleanly on top of its CONTRIBUTING, SECURITY, and governance edits. - **Dated records keep the old name**, matching the allowances `scripts/lint-legacy-name.mjs` already defines for the `prisma-next` identifier: `CHANGELOG.md`, `docs/releases/`, the ADRs, `projects/`, and `drive/`. Rewriting those would misreport what was true at the time, and a mechanical pass produced sentences like "Prisma Next becomes Prisma 8" turning into "Prisma 8 becomes Prisma 8". - **Identifiers are untouched.** `prisma-next` package names, paths, env vars (`PRISMA_NEXT_*`), `PrismaNext*` types, the `images/prisma-next.png` file, and the `prisma-next.md` primer (the docs still call it that) are all unchanged. Renaming any of those is a behaviour change with an upgrade path, not a docs fix. - **The sweep is mechanical.** The third commit is a `sed` of `Prisma Next` and `Prisma-next` to `Prisma 8` over 345 files. Three sentences that became self-referential (`ROADMAP.md`, `ROADMAP.html`, `scorecard.md`) were rewritten by hand. - **`README.md` supported-databases section** now says PostgreSQL and MongoDB are first-class and SQLite is planned next, which is what [/docs/orm](https://www.prisma.io/docs/orm) says. The previous text referenced work "before the 8.0.0-rc.1 release". - **Discord channel name dropped.** The README linked to a `prisma-next` channel I could not verify; it now links to Discord generically. ## Behavior changes & evidence - **`orm init` installs `prisma@latest`** instead of `prisma@next`, and falls back to `@prisma/cli-engine@latest` when the manifest does not pin the engine. [packages/1-framework/3-tooling/cli/src/orm/init.ts](packages/1-framework/3-tooling/cli/src/orm/init.ts), [packages/1-framework/3-tooling/cli/src/orm/init-packages.ts](packages/1-framework/3-tooling/cli/src/orm/init-packages.ts). Evidence: [packages/1-framework/3-tooling/cli/test/orm/init-install.test.ts](packages/1-framework/3-tooling/cli/test/orm/init-install.test.ts), [test/integration/test/cli.init-skill-distribution.integration.test.ts](test/integration/test/cli.init-skill-distribution.integration.test.ts). - **Scaffolded quick-reference notes and the skill quickstart** tell users to run `prisma@latest orm init`. [packages/1-framework/3-tooling/cli/src/commands/init/templates/quick-reference-postgres.md](packages/1-framework/3-tooling/cli/src/commands/init/templates/quick-reference-postgres.md), [skills/prisma-8/references/quickstart.md](skills/prisma-8/references/quickstart.md). Evidence: [packages/1-framework/3-tooling/cli/test/commands/init/__snapshots__/templates.test.ts.snap](packages/1-framework/3-tooling/cli/test/commands/init/__snapshots__/templates.test.ts.snap). - **No other runtime change.** Every other edit is prose in docs, comments, `package.json` descriptions, and `//` comments in test fixture schemas, which the emitter drops. ## Testing performed - `pnpm test` in `packages/1-framework/3-tooling/cli`: 115 files, 1437 tests passed - `pnpm lint:legacy-name`, `pnpm lint:docs`, `pnpm lint:skills`, `pnpm lint:rules:footprint`, `pnpm lint:manifests`: all pass (the `errors` README warning is pre-existing) - `pnpm fixtures:check` could not run in this worktree because the examples' `prisma` binary is not installed. The only schema edits are `//` comments, which do not reach the emitted contract. ## Skill update `skills/prisma-8/references/quickstart.md` is updated in the second commit: its `orm init` commands moved from `@prisma/cli@next` to `prisma@latest`, the same change the README makes. ## Alternatives considered - **Rename the identifiers too** (`prisma-next.md`, `PRISMA_NEXT_*`, `PrismaNext*` types, the image file). Each is a user-visible surface with an upgrade path, and the docs still name `prisma-next.md`. Left for a deliberate rename with upgrade instructions. - **Sweep the ADRs, changelog, and project write-ups as well.** The repo's own legacy-name lint exempts them as dated records, and the mechanical pass mangled sentences that describe the rename itself. Following the existing policy keeps the diff honest. - **Keep `@latest` on the commands, as the docs pages write them.** The v8 line is `latest` now, so the tag adds nothing; the README uses the bare `npm create prisma` and `npx prisma …` forms. ## Checklist - [x] All commits are signed off (`git commit -s`) per the [DCO](../CONTRIBUTING.md#developer-certificate-of-origin-dco). - [x] I read [CONTRIBUTING.md](../CONTRIBUTING.md) and the change is scoped to one logical concern. - [x] Tests are updated (the CLI install-command tests and snapshots). - [ ] The PR title is in `TML-NNNN: <sentence-case title>` form. No Linear ticket exists for this change. - [x] The **Skill update** section above is filled in. ## Notes for the reviewer The first two commits are small and worth reading line by line. The third is large but uniform; spot-check a few files rather than reading all 345. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Signed-off-by: willbot <w.a.madden+machine@gmail.com> Signed-off-by: Will Madden <madden@prisma.io> Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com> | 3 天前 | |
chore(deps-dev)(deps-dev): bump the dev-deps group across 1 directory with 10 updates (#30037) Bumps the dev-deps group with 10 updates in the / directory: | Package | From | To | | --- | --- | --- | | [@biomejs/biome](https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome) | `2.5.7` | `2.5.8` | | [dependency-cruiser](https://github.com/sverweij/dependency-cruiser) | `18.1.0` | `18.1.1` | | [pkg-pr-new](https://github.com/stackblitz-labs/pkg.pr.new/tree/HEAD/packages/cli) | `0.0.86` | `0.0.87` | | [skills](https://github.com/vercel-labs/skills) | `1.5.21` | `1.5.22` | | [turbo](https://github.com/vercel/turborepo) | `2.10.8` | `2.10.9` | | [wrangler](https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler) | `4.118.0` | `4.119.0` | | [@cloudflare/vitest-pool-workers](https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/vitest-pool-workers) | `0.20.1` | `0.20.3` | | [@cloudflare/workers-types](https://github.com/cloudflare/workerd) | `5.20260714.1` | `5.20260804.1` | | [@prisma/compute-sdk](https://github.com/prisma/project-compute) | `0.38.0` | `0.39.0` | | [@prisma/management-api-sdk](https://github.com/prisma/pdp-control-plane/tree/HEAD/packages/management-api-sdk) | `1.53.0` | `1.56.0` | Updates `@biomejs/biome` from 2.5.7 to 2.5.8 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/biomejs/biome/releases">@biomejs/biome's releases</a>.</em></p> <blockquote> <h2>Biome CLI v2.5.8</h2> <h2>2.5.8</h2> <h3>Patch Changes</h3> <ul> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/10710">#10710</a> <a href="https://github.com/biomejs/biome/commit/0a0fbc15d67c410c80dfae398903f845544fcd65"><code>0a0fbc1</code></a> Thanks <a href="https://github.com/dyc3"><code>@dyc3</code></a>! - Added a new nursery rule <a href="https://biomejs.dev/linter/rules/use-react-compiler/"><code>useReactCompiler</code></a>, which reports diagnostics from React Compiler lint mode.</p> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11251">#11251</a> <a href="https://github.com/biomejs/biome/commit/ea9dd8a93e65f849840415e8e26cd668aa1af913"><code>ea9dd8a</code></a> Thanks <a href="https://github.com/dyc3"><code>@dyc3</code></a>! - Improved performance of <a href="https://biomejs.dev/linter/rules/no-import-cycles/"><code>noImportCycles</code></a>.</p> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11247">#11247</a> <a href="https://github.com/biomejs/biome/commit/52b44d6795741d051bf703bd69c6cb447af8fd1d"><code>52b44d6</code></a> Thanks <a href="https://github.com/dyc3"><code>@dyc3</code></a>! - Added the nursery rule <a href="https://biomejs.dev/linter/rules/no-svelte-legacy-const/"><code>noSvelteLegacyConst</code></a>, which disallows legacy Svelte <code>{@const}</code> tags and recommends declaration tags with <code>$derived()</code>.</p> <p>Invalid:</p> <pre lang="svelte"><code>{#each boxes as box} {@const area = box.width * box.height} <p>{area}</p> {/each} </code></pre> <p>Valid:</p> <pre lang="svelte"><code>{#each boxes as box} {const area = $derived(box.width * box.height)} <p>{area}</p> {/each} </code></pre> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11252">#11252</a> <a href="https://github.com/biomejs/biome/commit/d5f570414fdcdddf62372e35c05f6dababad9287"><code>d5f5704</code></a> Thanks <a href="https://github.com/Turtle-Hwan"><code>@Turtle-Hwan</code></a>! - Fixed <a href="https://redirect.github.com/biomejs/biome/issues/11250">#11250</a>: <a href="https://biomejs.dev/linter/rules/use-await/"><code>useAwait</code></a> no longer reports async functions that contain an <code>await using</code> declaration.</p> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11143">#11143</a> <a href="https://github.com/biomejs/biome/commit/6be7be1b147d7b4352ff5625a78bd54a48958950"><code>6be7be1</code></a> Thanks <a href="https://github.com/vznh"><code>@vznh</code></a>! - Fixed <a href="https://redirect.github.com/biomejs/biome/issues/11017">#11017</a>: <a href="https://biomejs.dev/linter/rules/no-useless-undefined/"><code>noUselessUndefined</code></a> no longer reports <code>return undefined</code> when the enclosing function has a return type annotation other than <code>undefined</code> or <code>void</code>.</p> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11234">#11234</a> <a href="https://github.com/biomejs/biome/commit/caefe393c66340914c481f7ccfc82979cf76b61b"><code>caefe39</code></a> Thanks <a href="https://github.com/subotac"><code>@subotac</code></a>! - Fixed <a href="https://redirect.github.com/biomejs/biome/issues/11228">#11228</a>: CSS block comments between a declaration colon and value now preserve their source indentation.</p> <pre lang="diff"><code> :root { --font-stack: -/* comment */ + /* comment */ system-ui; } </code></pre> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11285">#11285</a> <a href="https://github.com/biomejs/biome/commit/bca1f73d939423056337bfd0a42cbdcb66bb1e3f"><code>bca1f73</code></a> Thanks <a href="https://github.com/denbezrukov"><code>@denbezrukov</code></a>! - Fixed <a href="https://redirect.github.com/biomejs/biome/issues/11280">#11280</a>: CSS formatting keeps comments inside functional pseudo-classes and pseudo-elements instead of moving them before the function name.</p> <pre lang="diff"><code>-:/* comment */ where(div) {} +:where(/* comment */ div) {} </code></pre> </li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/biomejs/biome/blob/main/packages/@biomejs/biome/CHANGELOG.md">@biomejs/biome's changelog</a>.</em></p> <blockquote> <h2>2.5.8</h2> <h3>Patch Changes</h3> <ul> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/10710">#10710</a> <a href="https://github.com/biomejs/biome/commit/0a0fbc15d67c410c80dfae398903f845544fcd65"><code>0a0fbc1</code></a> Thanks <a href="https://github.com/dyc3"><code>@dyc3</code></a>! - Added a new nursery rule <a href="https://biomejs.dev/linter/rules/use-react-compiler/"><code>useReactCompiler</code></a>, which reports diagnostics from React Compiler lint mode.</p> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11251">#11251</a> <a href="https://github.com/biomejs/biome/commit/ea9dd8a93e65f849840415e8e26cd668aa1af913"><code>ea9dd8a</code></a> Thanks <a href="https://github.com/dyc3"><code>@dyc3</code></a>! - Improved performance of <a href="https://biomejs.dev/linter/rules/no-import-cycles/"><code>noImportCycles</code></a>.</p> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11247">#11247</a> <a href="https://github.com/biomejs/biome/commit/52b44d6795741d051bf703bd69c6cb447af8fd1d"><code>52b44d6</code></a> Thanks <a href="https://github.com/dyc3"><code>@dyc3</code></a>! - Added the nursery rule <a href="https://biomejs.dev/linter/rules/no-svelte-legacy-const/"><code>noSvelteLegacyConst</code></a>, which disallows legacy Svelte <code>{@const}</code> tags and recommends declaration tags with <code>$derived()</code>.</p> <p>Invalid:</p> <pre lang="svelte"><code>{#each boxes as box} {@const area = box.width * box.height} <p>{area}</p> {/each} </code></pre> <p>Valid:</p> <pre lang="svelte"><code>{#each boxes as box} {const area = $derived(box.width * box.height)} <p>{area}</p> {/each} </code></pre> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11252">#11252</a> <a href="https://github.com/biomejs/biome/commit/d5f570414fdcdddf62372e35c05f6dababad9287"><code>d5f5704</code></a> Thanks <a href="https://github.com/Turtle-Hwan"><code>@Turtle-Hwan</code></a>! - Fixed <a href="https://redirect.github.com/biomejs/biome/issues/11250">#11250</a>: <a href="https://biomejs.dev/linter/rules/use-await/"><code>useAwait</code></a> no longer reports async functions that contain an <code>await using</code> declaration.</p> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11143">#11143</a> <a href="https://github.com/biomejs/biome/commit/6be7be1b147d7b4352ff5625a78bd54a48958950"><code>6be7be1</code></a> Thanks <a href="https://github.com/vznh"><code>@vznh</code></a>! - Fixed <a href="https://redirect.github.com/biomejs/biome/issues/11017">#11017</a>: <a href="https://biomejs.dev/linter/rules/no-useless-undefined/"><code>noUselessUndefined</code></a> no longer reports <code>return undefined</code> when the enclosing function has a return type annotation other than <code>undefined</code> or <code>void</code>.</p> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11234">#11234</a> <a href="https://github.com/biomejs/biome/commit/caefe393c66340914c481f7ccfc82979cf76b61b"><code>caefe39</code></a> Thanks <a href="https://github.com/subotac"><code>@subotac</code></a>! - Fixed <a href="https://redirect.github.com/biomejs/biome/issues/11228">#11228</a>: CSS block comments between a declaration colon and value now preserve their source indentation.</p> <pre lang="diff"><code> :root { --font-stack: -/* comment */ + /* comment */ system-ui; } </code></pre> </li> <li> <p><a href="https://redirect.github.com/biomejs/biome/pull/11285">#11285</a> <a href="https://github.com/biomejs/biome/commit/bca1f73d939423056337bfd0a42cbdcb66bb1e3f"><code>bca1f73</code></a> Thanks <a href="https://github.com/denbezrukov"><code>@denbezrukov</code></a>! - Fixed <a href="https://redirect.github.com/biomejs/biome/issues/11280">#11280</a>: CSS formatting keeps comments inside functional pseudo-classes and pseudo-elements instead of moving them before the function name.</p> <pre lang="diff"><code>-:/* comment */ where(div) {} +:where(/* comment */ div) {} </code></pre> </li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/biomejs/biome/commit/6b8f09c04394f2a9f72b89f9381724681169641a"><code>6b8f09c</code></a> ci: release (<a href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/11236">#11236</a>)</li> <li><a href="https://github.com/biomejs/biome/commit/23c0369c43b59284ca68c65883d6ede4228b6fb8"><code>23c0369</code></a> feat(lint): nursery noInvalidPropertyInitValue (<a href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/11187">#11187</a>)</li> <li><a href="https://github.com/biomejs/biome/commit/52b44d6795741d051bf703bd69c6cb447af8fd1d"><code>52b44d6</code></a> feat(lint/html): add <code>noSvelteLegacyConst</code> (<a href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/11247">#11247</a>)</li> <li><a href="https://github.com/biomejs/biome/commit/0a0fbc15d67c410c80dfae398903f845544fcd65"><code>0a0fbc1</code></a> feat(lint/js): add <code>useReactCompiler</code> (<a href="https://github.com/biomejs/biome/tree/HEAD/packages/@biomejs/biome/issues/10710">#10710</a>)</li> <li>See full diff in <a href="https://github.com/biomejs/biome/commits/@biomejs/biome@2.5.8/packages/@biomejs/biome">compare view</a></li> </ul> </details> <br /> Updates `dependency-cruiser` from 18.1.0 to 18.1.1 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/sverweij/dependency-cruiser/releases">dependency-cruiser's releases</a>.</em></p> <blockquote> <h2>v18.1.1</h2> <h2>👷 maintenance</h2> <ul> <li>1ee565bb/ 942cf969 build(npm): updates external dependencies</li> <li>f0061d15 fix: removes all unused catch parameters</li> <li>cbe062ae/ c0250f8d chore(tools): uses node permission model</li> <li>01c47439 fix(build): re-adds esbuild to the devDependencies</li> <li>e57d9fc2 chore: replaces eslint with oxlint (<a href="https://redirect.github.com/sverweij/dependency-cruiser/issues/1074">#1074</a>)</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/sverweij/dependency-cruiser/commit/da355e4cc82383f7b9744e0beb2f64d3c20f2e25"><code>da355e4</code></a> 18.1.1</li> <li><a href="https://github.com/sverweij/dependency-cruiser/commit/c0250f8dd06f622fba990fcd9b1d5da8c4bfaa1b"><code>c0250f8</code></a> chore(tools): makes the tools work again on node 22</li> <li><a href="https://github.com/sverweij/dependency-cruiser/commit/942cf969aa6174f1a4bfa91542dc6da37e5cdbcd"><code>942cf96</code></a> build(npm): updates external dependencies</li> <li><a href="https://github.com/sverweij/dependency-cruiser/commit/cbe062ae2b1994a7ce38bec9939562a33b193b84"><code>cbe062a</code></a> chore(tools): uses node permission model</li> <li><a href="https://github.com/sverweij/dependency-cruiser/commit/01c474397603d0a3db8288793c6bf362c18c7784"><code>01c4743</code></a> fix(build): re-adds esbuild to the devDependencies</li> <li><a href="https://github.com/sverweij/dependency-cruiser/commit/e57d9fc2f06a860eee3d7bf3667da05d52145a3e"><code>e57d9fc</code></a> chore: replaces eslint with oxlint (<a href="https://redirect.github.com/sverweij/dependency-cruiser/issues/1074">#1074</a>)</li> <li><a href="https://github.com/sverweij/dependency-cruiser/commit/f0061d1545e2c16a8ee0212f36306e2f41bad056"><code>f0061d1</code></a> fix: removes all unused catch parameters</li> <li><a href="https://github.com/sverweij/dependency-cruiser/commit/1ee565bb8ee935385b4288891849740125829f99"><code>1ee565b</code></a> build(npm): updates external dependencies</li> <li>See full diff in <a href="https://github.com/sverweij/dependency-cruiser/compare/v18.1.0...v18.1.1">compare view</a></li> </ul> </details> <br /> Updates `pkg-pr-new` from 0.0.86 to 0.0.87 <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/stackblitz-labs/pkg.pr.new/commit/d293ab292f1e71640630a6e4e4683235b92cdef7"><code>d293ab2</code></a> release: v0.0.87</li> <li>See full diff in <a href="https://github.com/stackblitz-labs/pkg.pr.new/commits/v0.0.87/packages/cli">compare view</a></li> </ul> </details> <br /> Updates `skills` from 1.5.21 to 1.5.22 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/vercel-labs/skills/releases">skills's releases</a>.</em></p> <blockquote> <h2>v1.5.22</h2> <h2>Changelog</h2> <ul> <li>fix: discover skills nested under two categories (<a href="https://redirect.github.com/vercel-labs/skills/issues/1866">#1866</a>)</li> <li>fix(update): normalize GitHub shorthand for project deletion checks (<a href="https://redirect.github.com/vercel-labs/skills/issues/1865">#1865</a>)</li> <li>fix: preserve locked GitHub host during updates (<a href="https://redirect.github.com/vercel-labs/skills/issues/1837">#1837</a>)</li> <li>Surface skills added upstream to well-known sources during update (<a href="https://redirect.github.com/vercel-labs/skills/issues/1824">#1824</a>)</li> <li>Make skills update work for well-known installs (incl. skills.sh packs) (<a href="https://redirect.github.com/vercel-labs/skills/issues/1821">#1821</a>)</li> <li>Preselect all skills when installing a skills.sh pack (<a href="https://redirect.github.com/vercel-labs/skills/issues/1820">#1820</a>)</li> <li>Add MiniMax Code agent support (<a href="https://redirect.github.com/vercel-labs/skills/issues/1814">#1814</a>)</li> <li>fix(remove): keep the lock entry while another agent still uses the skill (<a href="https://redirect.github.com/vercel-labs/skills/issues/1786">#1786</a>)</li> <li>fix(find): show all registry results in non-interactive search (<a href="https://redirect.github.com/vercel-labs/skills/issues/1748">#1748</a>)</li> <li>fix: store local path sources in lockfile using portable source (<a href="https://redirect.github.com/vercel-labs/skills/issues/1743">#1743</a>)</li> </ul> <h2>Contributors</h2> <p><a href="https://github.com/AndreaCovelli"><code>@AndreaCovelli</code></a>,<a href="https://github.com/IsmaelMartinez"><code>@IsmaelMartinez</code></a> <a href="https://github.com/SenseiMarv"><code>@SenseiMarv</code></a>,<a href="https://github.com/Ygilany"><code>@Ygilany</code></a> <a href="https://github.com/byapparov"><code>@byapparov</code></a>,<a href="https://github.com/hetaoBackend"><code>@hetaoBackend</code></a> <a href="https://github.com/mlekhi"><code>@mlekhi</code></a>,<a href="https://github.com/quuu"><code>@quuu</code></a></p> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/vercel-labs/skills/commit/a4d243c3d4f86cdf9385dd1b6a0733f6937e70b5"><code>a4d243c</code></a> v1.5.22</li> <li><a href="https://github.com/vercel-labs/skills/commit/ab4fc49265c443279a5deae20297e631470da68c"><code>ab4fc49</code></a> fix(find): show all returned search results (<a href="https://redirect.github.com/vercel-labs/skills/issues/1748">#1748</a>)</li> <li><a href="https://github.com/vercel-labs/skills/commit/644686b10ba6a6b563a1518e1a124a52e84460af"><code>644686b</code></a> Merge pull request <a href="https://redirect.github.com/vercel-labs/skills/issues/1743">#1743</a> from SenseiMarv/fix/store-local-path-sources-using-p...</li> <li><a href="https://github.com/vercel-labs/skills/commit/7533583f24a9a9be6fd5f783912f55c15a08b31e"><code>7533583</code></a> Merge branch 'main' into fix/store-local-path-sources-using-portable-source</li> <li><a href="https://github.com/vercel-labs/skills/commit/50d3b75443c24d2e224f5961cdd75e793c99d912"><code>50d3b75</code></a> fix project update GitHub shorthand clone (<a href="https://redirect.github.com/vercel-labs/skills/issues/1865">#1865</a>)</li> <li><a href="https://github.com/vercel-labs/skills/commit/653739a1ed1316cc2492ea81fbfcee14a45e4802"><code>653739a</code></a> fix: preserve locked GitHub host during updates (<a href="https://redirect.github.com/vercel-labs/skills/issues/1837">#1837</a>)</li> <li><a href="https://github.com/vercel-labs/skills/commit/65658a84d05961bbd0e2ea1afedb976946131315"><code>65658a8</code></a> Merge pull request <a href="https://redirect.github.com/vercel-labs/skills/issues/1786">#1786</a> from IsmaelMartinez/fix/remove-agent-subset-keeps-lock</li> <li><a href="https://github.com/vercel-labs/skills/commit/375f497e5c0e2d9ef743de372ce53545b1d77620"><code>375f497</code></a> Merge pull request <a href="https://redirect.github.com/vercel-labs/skills/issues/1866">#1866</a> from vercel-labs/fix/deeper-nested-skill-discovery</li> <li><a href="https://github.com/vercel-labs/skills/commit/dc045b90613a7c4d9c0feebbb96a27abedadf86b"><code>dc045b9</code></a> docs: update nested discovery depth</li> <li><a href="https://github.com/vercel-labs/skills/commit/6eeafb76573a798e330687c10fd83592bd619f8e"><code>6eeafb7</code></a> fix: discover skills nested under two categories</li> <li>Additional commits viewable in <a href="https://github.com/vercel-labs/skills/compare/v1.5.21...v1.5.22">compare view</a></li> </ul> </details> <br /> Updates `turbo` from 2.10.8 to 2.10.9 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/vercel/turborepo/releases">turbo's releases</a>.</em></p> <blockquote> <h2>Turborepo v2.10.9</h2> <!-- raw HTML omitted --> <h2>What's Changed</h2> <h3>Changelog</h3> <ul> <li>chore: Release Turborepo 2.10.8 by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/vercel/turborepo/pull/13626">vercel/turborepo#13626</a></li> <li>perf: Walk literal-prefix tree globs without wax compilation by <a href="https://github.com/charpeni"><code>@charpeni</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13522">vercel/turborepo#13522</a></li> <li>fix: Accept semver ranges in devEngines.packageManager.version by <a href="https://github.com/bangseongbeom"><code>@bangseongbeom</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13623">vercel/turborepo#13623</a></li> <li>docs: Explain affected package invalidation reasons by <a href="https://github.com/ghoullier"><code>@ghoullier</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13594">vercel/turborepo#13594</a></li> <li>perf(lockfiles): Borrow field-name scalars in the pnpm fast parser by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13648">vercel/turborepo#13648</a></li> <li>perf(repository): Avoid discarded alias allocation in Relationship by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13650">vercel/turborepo#13650</a></li> <li>perf(lockfiles): Drop redundant human_name clone for pnpm v7/v9 by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13649">vercel/turborepo#13649</a></li> <li>perf: Index workspace nodes by name in project_relationships by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13647">vercel/turborepo#13647</a></li> <li>perf: Share resolution identity lists across identical workspace closures by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13641">vercel/turborepo#13641</a></li> <li>docs: Fix duplicated word in runtime dependencies guide summary by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13630">vercel/turborepo#13630</a></li> <li>refactor: Remove turborepo-lsp dependency on turborepo-lib by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13631">vercel/turborepo#13631</a></li> <li>perf: Index Bun nested lockfile entries by name for fallback resolution by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13633">vercel/turborepo#13633</a></li> <li>perf: Memoize framework inference per package during task hashing by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13634">vercel/turborepo#13634</a></li> <li>perf: Avoid materializing transient declarations in external_dependencies by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13646">vercel/turborepo#13646</a></li> <li>perf: Enable shared closure DP for npm and yarn1 lockfiles by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13635">vercel/turborepo#13635</a></li> <li>perf: Parse pnpm explicit-key entries in the lockfile fast path by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13640">vercel/turborepo#13640</a></li> <li>perf: Parallelize resolution fingerprint hashing by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13642">vercel/turborepo#13642</a></li> <li>perf: Build resolution identity lists in parallel by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13643">vercel/turborepo#13643</a></li> <li>perf: Intern resolution identities as Arc<str> across closures by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13645">vercel/turborepo#13645</a></li> <li>fix: Compose affected tasks with package filters by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13656">vercel/turborepo#13656</a></li> <li>docs: Explain worktree cache path isolation by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13657">vercel/turborepo#13657</a></li> <li>fix: Upgrade brace-expansion to 5.0.9 by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13658">vercel/turborepo#13658</a></li> <li>docs: Correct verified inaccuracies in the Turborepo Agent Skill by <a href="https://github.com/charpeni"><code>@charpeni</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13644">vercel/turborepo#13644</a></li> <li>chore: Update Next.js to 16.3.0 by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13659">vercel/turborepo#13659</a></li> <li>fix: Don't use <code>eprintln!</code> in the panic hook by <a href="https://github.com/molofsky"><code>@molofsky</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13637">vercel/turborepo#13637</a></li> <li>fix: Invalidate only when Git ignore sources change by <a href="https://github.com/smasato"><code>@smasato</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13632">vercel/turborepo#13632</a></li> <li>docs: Update Geistdocs to 1.19.4 by <a href="https://github.com/christopherkindl"><code>@christopherkindl</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13680">vercel/turborepo#13680</a></li> <li>docs: Exclude Turborepo from its own OSS products menu by <a href="https://github.com/christopherkindl"><code>@christopherkindl</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13681">vercel/turborepo#13681</a></li> <li>docs: Use the geistdocs Turborepo logo in the navbar by <a href="https://github.com/christopherkindl"><code>@christopherkindl</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13682">vercel/turborepo#13682</a></li> <li>docs: Update redirected vercel.com/nextjs.org links to current targets by <a href="https://github.com/molebox"><code>@molebox</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13685">vercel/turborepo#13685</a></li> <li>refactor: Generalize native command arguments by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13664">vercel/turborepo#13664</a></li> <li>refactor: Move native contracts to tasks by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13665">vercel/turborepo#13665</a></li> <li>docs: Fix loadTransformers reference in turbo-codemod README by <a href="https://github.com/latent-9"><code>@latent-9</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13683">vercel/turborepo#13683</a></li> <li>refactor: Model native task execution explicitly by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13666">vercel/turborepo#13666</a></li> <li>feat: Compose aggregate native task dependencies by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13667">vercel/turborepo#13667</a></li> <li>fix: Respect aggregate task overrides by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13668">vercel/turborepo#13668</a></li> <li>test: Stabilize watch task inputs regression test by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13686">vercel/turborepo#13686</a></li> <li>feat: Parse Python quality tool declarations by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13669">vercel/turborepo#13669</a></li> <li>feat: Resolve Python quality plans by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13670">vercel/turborepo#13670</a></li> <li>refactor: Extract uv native task specs by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13671">vercel/turborepo#13671</a></li> <li>feat: Synthesize Python quality tasks by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13672">vercel/turborepo#13672</a></li> <li>test: Cover Python quality task commands by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13673">vercel/turborepo#13673</a></li> <li>feat: Hash Python quality task inputs by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13674">vercel/turborepo#13674</a></li> <li>test: Cover Python quality task graph by <a href="https://github.com/anthonyshew"><code>@anthonyshew</code></a> in <a href="https://redirect.github.com/vercel/turborepo/pull/13675">vercel/turborepo#13675</a></li> <li>chore: Release Turborepo 2.10.9-canary.1 by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/vercel/turborepo/pull/13687">vercel/turborepo#13687</a></li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/vercel/turborepo/commit/33237d4be13d7b74768c2cf3353b19cfa8d1af7c"><code>33237d4</code></a> publish 2.10.9 to registry</li> <li><a href="https://github.com/vercel/turborepo/commit/3b0e57f1289b2a6b3d6dd402bce928469d3b25fa"><code>3b0e57f</code></a> fix: Prevent Windows process cleanup PID reuse (<a href="https://redirect.github.com/vercel/turborepo/issues/13695">#13695</a>)</li> <li><a href="https://github.com/vercel/turborepo/commit/efe4e1bdf665f2950cf89d7968907de36c2f0737"><code>efe4e1b</code></a> fix: Prune Bun wildcard workspace dev dependencies (<a href="https://redirect.github.com/vercel/turborepo/issues/13694">#13694</a>)</li> <li><a href="https://github.com/vercel/turborepo/commit/a98e5cde97796088c6107684a64a40a967cd1ef0"><code>a98e5cd</code></a> docs: Document dependency-driven Python tasks (<a href="https://redirect.github.com/vercel/turborepo/issues/13676">#13676</a>)</li> <li><a href="https://github.com/vercel/turborepo/commit/c09a92f526b6dca9ea0243922f680803779759cd"><code>c09a92f</code></a> chore: Release Turborepo 2.10.9-canary.1 (<a href="https://redirect.github.com/vercel/turborepo/issues/13687">#13687</a>)</li> <li><a href="https://github.com/vercel/turborepo/commit/09bd548dddbff2a29086bdef7cb07b02d5e5458a"><code>09bd548</code></a> test: Cover Python quality task graph (<a href="https://redirect.github.com/vercel/turborepo/issues/13675">#13675</a>)</li> <li><a href="https://github.com/vercel/turborepo/commit/3584a5fb8edac9efc826fdea57e92088505fc76a"><code>3584a5f</code></a> feat: Hash Python quality task inputs (<a href="https://redirect.github.com/vercel/turborepo/issues/13674">#13674</a>)</li> <li><a href="https://github.com/vercel/turborepo/commit/0d43ff3cbf5ac8873c646a84b2fd7ae53097e08d"><code>0d43ff3</code></a> test: Cover Python quality task commands (<a href="https://redirect.github.com/vercel/turborepo/issues/13673">#13673</a>)</li> <li><a href="https://github.com/vercel/turborepo/commit/94708adc6bc19b41805741cc5a15ac5467a481cf"><code>94708ad</code></a> feat: Synthesize Python quality tasks (<a href="https://redirect.github.com/vercel/turborepo/issues/13672">#13672</a>)</li> <li><a href="https://github.com/vercel/turborepo/commit/e14f04ec6c2dc2791b0a3beb32df7515b31b3d4b"><code>e14f04e</code></a> refactor: Extract uv native task specs (<a href="https://redirect.github.com/vercel/turborepo/issues/13671">#13671</a>)</li> <li>Additional commits viewable in <a href="https://github.com/vercel/turborepo/compare/v2.10.8...v2.10.9">compare view</a></li> </ul> </details> <br /> Updates `wrangler` from 4.118.0 to 4.119.0 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/cloudflare/workers-sdk/releases">wrangler's releases</a>.</em></p> <blockquote> <h2>wrangler@4.119.0</h2> <h3>Minor Changes</h3> <ul> <li> <p><a href="https://redirect.github.com/cloudflare/workers-sdk/pull/14952">#14952</a> <a href="https://github.com/cloudflare/workers-sdk/commit/20470fa8b09761c50b5c2c1d6a5f2652b61bd271"><code>20470fa</code></a> Thanks <a href="https://github.com/nelsonjsduarte"><code>@nelsonjsduarte</code></a>! - Add <code>--parse-type</code> flag to <code>wrangler ai-search create</code></p> <p><code>wrangler ai-search create</code> now accepts <code>--parse-type</code> to control how a website data source discovers URLs. <code>sitemap</code> (the default) reads XML sitemaps; <code>discover</code> follows links recursively.</p> <p>Previously the parse type could only be chosen through the interactive wizard, which was skipped whenever <code>--source</code> was supplied — so it was impossible to create a <code>discover</code> instance from a script.</p> <pre lang="sh"><code>wrangler ai-search create my-instance \ --type web-crawler \ --source https://example.com \ --parse-type discover </code></pre> <p>The interactive wizard now offers <code>Discover</code> alongside <code>Sitemap</code>. <code>--parse-type</code> is only valid with <code>--type web-crawler</code>; passing it with <code>--type builtin</code> or <code>--type r2</code> is rejected, since the API stores the value for those source types but never reads it. When the flag is omitted in non-interactive mode the field is left unset and the API default (<code>sitemap</code>) applies.</p> </li> <li> <p><a href="https://redirect.github.com/cloudflare/workers-sdk/pull/14941">#14941</a> <a href="https://github.com/cloudflare/workers-sdk/commit/266172b98c27770e6d48d3fd42790e2125115e5e"><code>266172b</code></a> Thanks <a href="https://github.com/nickpatt"><code>@nickpatt</code></a>! - Improve the Local Explorer's Observability views</p> <p><code>console.log</code> messages now render the way the console would (JSON-encoded strings are unwrapped and multi-argument logs are joined), traces and events can be looked up by trace or span id from the search bar, and an event's "View trace" button jumps to the exact invocation that emitted it — even when a trace_id spans several invocations (e.g. a subrequest or self fetch).</p> </li> <li> <p><a href="https://redirect.github.com/cloudflare/workers-sdk/pull/14064">#14064</a> <a href="https://github.com/cloudflare/workers-sdk/commit/a9e5abb8c0c2e7895b0bb09c6c8e8ffd3dbc3bc0"><code>a9e5abb</code></a> Thanks <a href="https://github.com/petebacondarwin"><code>@petebacondarwin</code></a>! - Add support for OAuth 2.0 Device Authorization Grant to <code>wrangler login</code></p> <p>Run <code>wrangler login --device</code> to authenticate without a local callback server. Useful in containers, remote SSH sessions, Codespaces, and any other environment where <code>localhost:8976</code> is unreachable from your browser.</p> <p>The new flow:</p> <ul> <li>prints the verification URL and user code to the terminal,</li> <li>attempts to open the verification URL in your default browser automatically (suppressed via <code>--browser=false</code>),</li> <li>and polls the token endpoint until you approve the request (with a 5-minute hard cap).</li> </ul> <p>The verification URL is supplied by the authorization server, so it is rejected unless it is an <code>https</code> URL on the same auth domain the device code was requested from — it is never printed or opened otherwise.</p> <p><code>--callback-host</code> and <code>--callback-port</code> cannot be combined with <code>--device</code>, since this flow does not start a local callback server.</p> </li> </ul> <h3>Patch Changes</h3> <ul> <li> <p><a href="https://redirect.github.com/cloudflare/workers-sdk/pull/14984">#14984</a> <a href="https://github.com/cloudflare/workers-sdk/commit/9c7453837e3293787c0cb1778520f630aea7e5ca"><code>9c74538</code></a> Thanks <a href="https://github.com/apps/dependabot"><code>@dependabot</code></a>! - Update dependencies of "miniflare", "wrangler"</p> <p>The following dependency versions have been updated:</p> <table> <thead> <tr> <th>Dependency</th> <th>From</th> <th>To</th> </tr> </thead> <tbody> <tr> <td><code>@cloudflare/workers-types</code></td> <td>^5.20260730.1</td> <td>^5.20260731.1</td> </tr> <tr> <td>workerd</td> <td>1.20260730.1</td> <td>1.20260731.1</td> </tr> </tbody> </table> </li> <li> <p><a href="https://redirect.github.com/cloudflare/workers-sdk/pull/15012">#15012</a> <a href="https://github.com/cloudflare/workers-sdk/commit/0d33cb8dfb1d6289cb180f16e0e60cd7073a1b1b"><code>0d33cb8</code></a> Thanks <a href="https://github.com/apps/dependabot"><code>@dependabot</code></a>! - Update dependencies of "miniflare", "wrangler"</p> <p>The following dependency versions have been updated:</p> </li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/cloudflare/workers-sdk/commit/2938c01a9da2424a3f2d3c73bd870c7b75b39753"><code>2938c01</code></a> Version Packages (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler/issues/15021">#15021</a>)</li> <li><a href="https://github.com/cloudflare/workers-sdk/commit/b6a862966aaaa4d2bc7845a349636a6af65313fe"><code>b6a8629</code></a> Revert "Version Packages (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler/issues/14977">#14977</a>)" (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler/issues/15033">#15033</a>)</li> <li><a href="https://github.com/cloudflare/workers-sdk/commit/42c4227798c21cfde8dbfb087be1bb9078dab185"><code>42c4227</code></a> Version Packages (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler/issues/14977">#14977</a>)</li> <li><a href="https://github.com/cloudflare/workers-sdk/commit/511635c70821d33c64bb377e2c4a6be27683801f"><code>511635c</code></a> [wrangler] Skip the CAA half of the unenv-preset testDns E2E (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler/issues/15016">#15016</a>)</li> <li><a href="https://github.com/cloudflare/workers-sdk/commit/ebd1dfd3778dd3fdb9a63a5596852287eb4029b1"><code>ebd1dfd</code></a> [vite-plugin] Surface Local Explorer API to headless agents, matching wrangle...</li> <li><a href="https://github.com/cloudflare/workers-sdk/commit/a9e5abb8c0c2e7895b0bb09c6c8e8ffd3dbc3bc0"><code>a9e5abb</code></a> [wrangler] Add OAuth 2.0 Device Authorization Grant support (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler/issues/14064">#14064</a>)</li> <li><a href="https://github.com/cloudflare/workers-sdk/commit/20470fa8b09761c50b5c2c1d6a5f2652b61bd271"><code>20470fa</code></a> [wrangler] Add --parse-type to ai-search create (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler/issues/14952">#14952</a>)</li> <li><a href="https://github.com/cloudflare/workers-sdk/commit/5fd61271cdb7c661eace968ae4cbae40d2fbdc37"><code>5fd6127</code></a> [miniflare] De-flake rate limit tests at bucket boundaries (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/wrangler/issues/14961">#14961</a>)</li> <li>See full diff in <a href="https://github.com/cloudflare/workers-sdk/commits/wrangler@4.119.0/packages/wrangler">compare view</a></li> </ul> </details> <br /> Updates `@cloudflare/vitest-pool-workers` from 0.20.1 to 0.20.3 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/cloudflare/workers-sdk/releases">@cloudflare/vitest-pool-workers's releases</a>.</em></p> <blockquote> <h2><code>@cloudflare/vitest-pool-workers</code><a href="https://github.com/0"><code>@0</code></a>.20.3</h2> <h3>Patch Changes</h3> <ul> <li> <p><a href="https://redirect.github.com/cloudflare/workers-sdk/pull/15013">#15013</a> <a href="https://github.com/cloudflare/workers-sdk/commit/8cf78c83cb4c64be8b458d7bd618b47e7c6e7d25"><code>8cf78c8</code></a> Thanks <a href="https://github.com/dario-piotrowicz"><code>@dario-piotrowicz</code></a>! - Update undici from 7.28.0 to 7.29.0</p> </li> <li> <p>Updated dependencies [<a href="https://github.com/cloudflare/workers-sdk/commit/35c87e97199fb4548d4d9aaac024c3e07be5734e"><code>35c87e9</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/b4f0c9760bcab1e04cf1a9c8859feed8b4fc6487"><code>b4f0c97</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/8cf78c83cb4c64be8b458d7bd618b47e7c6e7d25"><code>8cf78c8</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/a60ff4dea0bbae8775726d9cf885655b56460a30"><code>a60ff4d</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/99eb50ce1d3420a50ae0e95958bf49d65874706e"><code>99eb50c</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/35c87e97199fb4548d4d9aaac024c3e07be5734e"><code>35c87e9</code></a>]:</p> <ul> <li>wrangler@4.120.0</li> <li><a href="mailto:miniflare@5.20260801.1-alpha">miniflare@5.20260801.1-alpha</a></li> </ul> </li> </ul> <h2><code>@cloudflare/vitest-pool-workers</code><a href="https://github.com/0"><code>@0</code></a>.20.2</h2> <h3>Patch Changes</h3> <ul> <li>Updated dependencies [<a href="https://github.com/cloudflare/workers-sdk/commit/20470fa8b09761c50b5c2c1d6a5f2652b61bd271"><code>20470fa</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/9c7453837e3293787c0cb1778520f630aea7e5ca"><code>9c74538</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/266172b98c27770e6d48d3fd42790e2125115e5e"><code>266172b</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/a88d1691d57bf44616ad15556a51b7f8ca17375c"><code>a88d169</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/a88d1691d57bf44616ad15556a51b7f8ca17375c"><code>a88d169</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/daf65f28cecf35e251dc6e476d5bbd82972d68de"><code>daf65f2</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/a9e5abb8c0c2e7895b0bb09c6c8e8ffd3dbc3bc0"><code>a9e5abb</code></a>]: <ul> <li>wrangler@4.119.0</li> <li><a href="mailto:miniflare@5.20260801.0-alpha">miniflare@5.20260801.0-alpha</a></li> </ul> </li> </ul> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/cloudflare/workers-sdk/blob/main/packages/vitest-pool-workers/CHANGELOG.md">@cloudflare/vitest-pool-workers's changelog</a>.</em></p> <blockquote> <h2>0.20.3</h2> <h3>Patch Changes</h3> <ul> <li> <p><a href="https://redirect.github.com/cloudflare/workers-sdk/pull/15013">#15013</a> <a href="https://github.com/cloudflare/workers-sdk/commit/8cf78c83cb4c64be8b458d7bd618b47e7c6e7d25"><code>8cf78c8</code></a> Thanks <a href="https://github.com/dario-piotrowicz"><code>@dario-piotrowicz</code></a>! - Update undici from 7.28.0 to 7.29.0</p> </li> <li> <p>Updated dependencies [<a href="https://github.com/cloudflare/workers-sdk/commit/35c87e97199fb4548d4d9aaac024c3e07be5734e"><code>35c87e9</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/b4f0c9760bcab1e04cf1a9c8859feed8b4fc6487"><code>b4f0c97</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/8cf78c83cb4c64be8b458d7bd618b47e7c6e7d25"><code>8cf78c8</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/a60ff4dea0bbae8775726d9cf885655b56460a30"><code>a60ff4d</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/99eb50ce1d3420a50ae0e95958bf49d65874706e"><code>99eb50c</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/35c87e97199fb4548d4d9aaac024c3e07be5734e"><code>35c87e9</code></a>]:</p> <ul> <li>wrangler@4.120.0</li> <li><a href="mailto:miniflare@5.20260801.1-alpha">miniflare@5.20260801.1-alpha</a></li> </ul> </li> </ul> <h2>0.20.2</h2> <h3>Patch Changes</h3> <ul> <li>Updated dependencies [<a href="https://github.com/cloudflare/workers-sdk/commit/20470fa8b09761c50b5c2c1d6a5f2652b61bd271"><code>20470fa</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/9c7453837e3293787c0cb1778520f630aea7e5ca"><code>9c74538</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/266172b98c27770e6d48d3fd42790e2125115e5e"><code>266172b</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/a88d1691d57bf44616ad15556a51b7f8ca17375c"><code>a88d169</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/a88d1691d57bf44616ad15556a51b7f8ca17375c"><code>a88d169</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/daf65f28cecf35e251dc6e476d5bbd82972d68de"><code>daf65f2</code></a>, <a href="https://github.com/cloudflare/workers-sdk/commit/a9e5abb8c0c2e7895b0bb09c6c8e8ffd3dbc3bc0"><code>a9e5abb</code></a>]: <ul> <li>wrangler@4.119.0</li> <li><a href="mailto:miniflare@5.20260801.0-alpha">miniflare@5.20260801.0-alpha</a></li> </ul> </li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/cloudflare/workers-sdk/commit/b0aea76e0a7862b4ecfbe44232fb0a56ba3a2525"><code>b0aea76</code></a> Version Packages (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/vitest-pool-workers/issues/15036">#15036</a>)</li> <li><a href="https://github.com/cloudflare/workers-sdk/commit/2938c01a9da2424a3f2d3c73bd870c7b75b39753"><code>2938c01</code></a> Version Packages (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/vitest-pool-workers/issues/15021">#15021</a>)</li> <li><a href="https://github.com/cloudflare/workers-sdk/commit/b6a862966aaaa4d2bc7845a349636a6af65313fe"><code>b6a8629</code></a> Revert "Version Packages (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/vitest-pool-workers/issues/14977">#14977</a>)" (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/vitest-pool-workers/issues/15033">#15033</a>)</li> <li><a href="https://github.com/cloudflare/workers-sdk/commit/42c4227798c21cfde8dbfb087be1bb9078dab185"><code>42c4227</code></a> Version Packages (<a href="https://github.com/cloudflare/workers-sdk/tree/HEAD/packages/vitest-pool-workers/issues/14977">#14977</a>)</li> <li>See full diff in <a href="https://github.com/cloudflare/workers-sdk/commits/@cloudflare/vitest-pool-workers@0.20.3/packages/vitest-pool-workers">compare view</a></li> </ul> </details> <br /> Updates `@cloudflare/workers-types` from 5.20260714.1 to 5.20260804.1 <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/cloudflare/workerd/commits">compare view</a></li> </ul> </details> <br /> Updates `@prisma/compute-sdk` from 0.38.0 to 0.39.0 <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/prisma/project-compute/commits">compare view</a></li> </ul> </details> <br /> Updates `@prisma/management-api-sdk` from 1.53.0 to 1.56.0 <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/prisma/pdp-control-plane/commits/HEAD/packages/management-api-sdk">compare view</a></li> </ul> </details> <br /> Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore <dependency name> major version` will close this group update PR and stop Dependabot creating any more for the specific dependency's major version (unless you unignore this specific dependency's major version or upgrade to it yourself) - `@dependabot ignore <dependency name> minor version` will close this group update PR and stop Dependabot creating any more for the specific dependency's minor version (unless you unignore this specific dependency's minor version or upgrade to it yourself) - `@dependabot ignore <dependency name>` will close this group update PR and stop Dependabot creating any more for the specific dependency (unless you unignore this specific dependency or upgrade to it yourself) - `@dependabot unignore <dependency name>` will remove all of the ignore conditions of the specified dependency - `@dependabot unignore <dependency name> <ignore condition>` will remove the ignore condition of the specified dependency and ignore conditions </details> Signed-off-by: willbot <w.a.madden+machine@gmail.com> Signed-off-by: Will Madden <madden@prisma.io> Co-authored-by: willbot <w.a.madden+machine@gmail.com> | 28 天前 | |
chore(release): bump to 8.0.0-rc.10 (#30268) `8.0.0-rc.9` → `8.0.0-rc.10`. ## What ships The user-facing changes are in [`docs/releases/v8.0.0-rc.10.md`](docs/releases/v8.0.0-rc.10.md), mirrored into `CHANGELOG.md`. Review that file as the release's public statement. In short: the Prisma 8 rename reaches every identifier a project can see (schema header, environment variables, config directory, primer file), the emitted contract gains `Models`, `Scalars`, `Shape`, and a working `ResultType` on ORM queries, `db sign` sets the `db` ref so the first plan after adoption stays incremental, and the language server completes attribute names. ## Skill audit I checked the bundled `prisma-8` skill against every PR in the range. The in-range PRs had already updated the references for `db sign` ref advancement and its two flags (#30251), the rename (#30262), the `Models` and `Shape` types (#30231), and the rc.9-to-rc.10 upgrade recipes for both audiences. Two gaps are fixed in the second commit: the skill date stamp, and `references/contract.md` never mentioned the `// use prisma-8` schema header at all. `library_version` was stamped to rc.10 by `pnpm bump-version`. ## Merging this PR ships the release The push to `main` carries the bumped root `version`. The `Publish to npm` workflow publishes `8.0.0-rc.10` under the `latest` dist-tag and creates a matching pre-release GitHub Release whose body is the notes file above. See [`docs/oss/versioning.md`](docs/oss/versioning.md). A matching prisma/web PR updates the docs site for this release and should merge once this one is published. 🤖 Generated with [Claude Code](https://claude.com/claude-code) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added named model and result types for contracts. * Added language-server completion for attributes and named arguments. * Added nullable metadata and validation for to-one relations. * Added reference-selection controls and JSON metadata to `db sign`; the `db` reference now advances by default. * **Bug Fixes** * Improved migration planning and PostgreSQL connection handling. * Corrected package tag handling in `orm init`. * **Documentation** * Documented Prisma 8 schema headers, renamed CLI environment variables, and updated upgrade guidance. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Signed-off-by: willbot <w.a.madden+machine@gmail.com> Signed-off-by: Will Madden <madden@prisma.io> Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com> | 2 天前 | |
feat(cli)!: stop publishing the prisma-next CLI — the unified prisma-cli replaces it (#30005) ## At a glance Before this PR, a Prisma Next user installed `prisma-next` from npm and their project looked like this: ```bash prisma-next db update ``` ```ts // prisma-next.config.ts import { defineConfig } from '@prisma/orm-postgres/config'; export default defineConfig({ contract: './contract.ts', output: './generated', }); ``` After this PR, this repo publishes no CLI binary at all. Users install `@prisma/cli@next` (the unified Prisma CLI, built in the prisma-cli repo) and run: ```bash prisma-cli db update ``` ```ts // prisma.config.ts import { defineConfig } from '@prisma/cli-engine'; import { defineConfig as ormConfig } from '@prisma/orm-postgres/config'; export default defineConfig({ orm: ormConfig({ contract: './contract.ts', output: './generated', }), }); ``` Same commands, same behaviour — the ORM commands this repo builds are mounted into the unified CLI as its `orm` command family. ## The decision Stop publishing a CLI from this repo, and delete the command-line shell that made publishing one possible. Some context for anyone who hasn't followed the port series: the ORM CLI used to be a commander program in this repo — commander parsed the flags, per-command renderers wrote styled output to stdout, and a `handleResult()` helper mapped results to exit codes. Over the previous PRs, every command was re-implemented as a command definition for `@prisma/cli-engine`, the shared CLI framework that the unified `prisma-cli` binary is built on. The engine parses arguments, prints help, renders each command's result envelope, and owns the exit code. That left the commander shell and the published `prisma-next` bin as duplicates of things the engine and the unified CLI already do. This PR removes both. The one deliberate survivor is the migration-file runtime: user-authored `migration.ts` files execute through their own small clipanion CLI (`MigrationCLI.run`) with a 0/1/2 exit scheme. That is a public contract of authored migrations, not part of the shell, so it stays — and a dedicated test now pins the exit scheme so the cutover cannot silently change it. ## What the PR does, step by step **1. The published bin goes away; a workspace-local bin stays.** `packages/9-public/prisma-next` (the bin-only shim package from ADRs 211/242) is deleted, and the public facade packages no longer declare launcher bins. `@internal/cli` keeps a workspace-local `prisma-next` bin pointing at `dist/bin.mjs` — a thin engine entry (`runOrmCli(process)`) that mounts the same 22 command paths the unified CLI mounts — so the repo's examples, dev flows, and spawn smoke tests keep working without a published package. The "install the CLI" journey now belongs to the unified CLI. **2. The commander shell is deleted.** Every command runs as an engine definition under `src/orm/`. Commander, the renderers, `handleResult`, the global-flag resolver, the shutdown handler, and the help formatter are gone; the engine provides all of it. **3. The legacy tests are re-expressed on the engine harness.** Commander-era tests asserted styled stdout, which no longer exists here. They were ported to `createTestCli`, the in-process engine harness, asserting data: the settled result envelope, emitted events, and the exit code — no stdout parsing, no snapshots. Pure formatting tests became presentation-model data assertions or were deleted with a per-file reason recorded in the porting ledger (a legacy test could only be deleted when the behaviour died with the shell or an engine test with the same name covers it). One suite, `cli.bin-smoke.e2e.test.ts`, still spawns the real bin to pin startup, dispatch, exit-code surfacing, and the telemetry sender spawn. **4. Config consolidates on `prisma.config.ts`, with a deprecation path.** The unified CLI reads `prisma.config.ts` in the nested shape shown above (`defineConfig({ orm: ormConfig({ … }) })` from `@prisma/cli-engine`). All 226 config files in this repo were renamed and rewrapped. The loader prefers the new filename and shape, and still accepts the old `prisma-next.config.*` filename and the old flat shape, each with a stderr deprecation warning (`CONFIG.DEPRECATED_FILENAME`, `CONFIG.DEPRECATED_SHAPE`), so existing projects keep loading until the codemod story lands. The bin adapter unwraps the `orm` section before handing config to command handlers, so the handlers are untouched. **5. `init` scaffolds for the unified CLI.** New projects get `prisma.config.ts` in the engine shape, package scripts that invoke `prisma-cli`, and devDependencies `@prisma/cli@next` + `@prisma/cli-engine` (the config file imports the engine's `defineConfig`). **6. User-facing prose names the bin users actually have.** The engine only substitutes its `{bin}` placeholder in help examples and command redirects, so ~100 hardcoded `prisma-next <cmd>` strings in next-actions, fix suggestions, and init templates now say `prisma-cli`. Telemetry threads the settled exit code through the pipeline. The framework-vocabulary ratchet drops 364 → 308. **7. Docs catch up.** The root README installs `@prisma/cli@next`; the CLI package README describes the engine entry; the style guide, error reference, and e2e-patterns doc describe commander in the past tense; ADR 242 carries a supersession note for the retired bin distribution; ADR 239 records the `CLI.*` error namespace as shared with `@prisma/cli-engine`. ## Operator-review items - **`init`'s devDependency choice**: `@prisma/cli@next` + `@prisma/cli-engine`, scripts on the `prisma-cli` bin. The alternative — the `prisma-next` npm name living on as an rc channel published from the prisma-cli repo — does not exist yet; scaffolding it today would install the stale artifact this repo used to publish. - **The npm `prisma-next` name**: this PR only stops publishing it; deprecating or handing off the name is operator-owned. - **Generated-artifact headers**: emitted artifacts still carry `prisma-next`-flavoured headers. The emitter cannot know which bin invoked it, and changing the header would churn every committed fixture, so they were left alone — flagging for an explicit call. - **Hardcoded `prisma-cli` in remediation strings**: the ~100 next-action/fix strings name the unified bin literally because the engine has no `{bin}` templating outside help/redirects. If the engine grows that affordance, these should switch to it. ## Verification | Check | Result | | --- | --- | | root `pnpm build` | exit 0 | | cli `pnpm typecheck` / `pnpm lint` / `pnpm test` | exit 0 / exit 0 (264 infos) / 113 files, 1410/1410 | | config-loader `pnpm test` | exit 0 — 53/53 | | `pnpm test:integration` (full) | 10 failed files on the loaded full run → triaged: 1 real (a retry-hint assertion behind the prose sweep — fixed), the known machine-local timezone artifact (`issues-28192-pg-historical-dates`, 2 tests), a mongodb-memory-server port collision, and 7 timeout flakes; everything except the timezone artifact passes isolated with `TEST_TIMEOUT_MULTIPLIER=2` (34/34 + 2/2) | | `pnpm fixtures:check` | exit 0, no fixture diffs (after repairing the two cutover leftovers it caught — see the last commit) | | `pnpm lint:deps` | exit 0 | | `node scripts/lint-framework-vocabulary.mjs` | exit 0 (count 308 = threshold) | The cutover's divergence record and porting ledger live in the prisma-cli repo on branch `s5-cutover-divergences` (`.drive/projects/prisma-cli-v8/assets/s2/parity-divergences-s5-cutover.md`, `assets/s5/cutover-ledger.md`). ## Alternatives considered - **Keep publishing `prisma-next` as a thin shim over the engine bin.** Rejected: it would ship a second binary with identical behaviour under a stale name, while the rollout plan's happy path is the unified CLI. - **Port the stdout-formatting tests onto the engine renderer instead of deleting them.** Rejected: the renderer belongs to the engine and is tested there; re-asserting its output here would pin another repo's presentation. - **A hard cut on config filenames — engine semantics only, no fallback.** Rejected for this repo's own users: the deprecation path keeps every existing project loading (with a warning) until the codemod story lands post-rc. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Signed-off-by: willbot <w.a.madden+machine@gmail.com> Signed-off-by: Will Madden <madden@prisma.io> Co-authored-by: Claude Fable 5 <noreply@anthropic.com> | 1 个月前 | |
feat(cli)!: stop publishing the prisma-next CLI — the unified prisma-cli replaces it (#30005) ## At a glance Before this PR, a Prisma Next user installed `prisma-next` from npm and their project looked like this: ```bash prisma-next db update ``` ```ts // prisma-next.config.ts import { defineConfig } from '@prisma/orm-postgres/config'; export default defineConfig({ contract: './contract.ts', output: './generated', }); ``` After this PR, this repo publishes no CLI binary at all. Users install `@prisma/cli@next` (the unified Prisma CLI, built in the prisma-cli repo) and run: ```bash prisma-cli db update ``` ```ts // prisma.config.ts import { defineConfig } from '@prisma/cli-engine'; import { defineConfig as ormConfig } from '@prisma/orm-postgres/config'; export default defineConfig({ orm: ormConfig({ contract: './contract.ts', output: './generated', }), }); ``` Same commands, same behaviour — the ORM commands this repo builds are mounted into the unified CLI as its `orm` command family. ## The decision Stop publishing a CLI from this repo, and delete the command-line shell that made publishing one possible. Some context for anyone who hasn't followed the port series: the ORM CLI used to be a commander program in this repo — commander parsed the flags, per-command renderers wrote styled output to stdout, and a `handleResult()` helper mapped results to exit codes. Over the previous PRs, every command was re-implemented as a command definition for `@prisma/cli-engine`, the shared CLI framework that the unified `prisma-cli` binary is built on. The engine parses arguments, prints help, renders each command's result envelope, and owns the exit code. That left the commander shell and the published `prisma-next` bin as duplicates of things the engine and the unified CLI already do. This PR removes both. The one deliberate survivor is the migration-file runtime: user-authored `migration.ts` files execute through their own small clipanion CLI (`MigrationCLI.run`) with a 0/1/2 exit scheme. That is a public contract of authored migrations, not part of the shell, so it stays — and a dedicated test now pins the exit scheme so the cutover cannot silently change it. ## What the PR does, step by step **1. The published bin goes away; a workspace-local bin stays.** `packages/9-public/prisma-next` (the bin-only shim package from ADRs 211/242) is deleted, and the public facade packages no longer declare launcher bins. `@internal/cli` keeps a workspace-local `prisma-next` bin pointing at `dist/bin.mjs` — a thin engine entry (`runOrmCli(process)`) that mounts the same 22 command paths the unified CLI mounts — so the repo's examples, dev flows, and spawn smoke tests keep working without a published package. The "install the CLI" journey now belongs to the unified CLI. **2. The commander shell is deleted.** Every command runs as an engine definition under `src/orm/`. Commander, the renderers, `handleResult`, the global-flag resolver, the shutdown handler, and the help formatter are gone; the engine provides all of it. **3. The legacy tests are re-expressed on the engine harness.** Commander-era tests asserted styled stdout, which no longer exists here. They were ported to `createTestCli`, the in-process engine harness, asserting data: the settled result envelope, emitted events, and the exit code — no stdout parsing, no snapshots. Pure formatting tests became presentation-model data assertions or were deleted with a per-file reason recorded in the porting ledger (a legacy test could only be deleted when the behaviour died with the shell or an engine test with the same name covers it). One suite, `cli.bin-smoke.e2e.test.ts`, still spawns the real bin to pin startup, dispatch, exit-code surfacing, and the telemetry sender spawn. **4. Config consolidates on `prisma.config.ts`, with a deprecation path.** The unified CLI reads `prisma.config.ts` in the nested shape shown above (`defineConfig({ orm: ormConfig({ … }) })` from `@prisma/cli-engine`). All 226 config files in this repo were renamed and rewrapped. The loader prefers the new filename and shape, and still accepts the old `prisma-next.config.*` filename and the old flat shape, each with a stderr deprecation warning (`CONFIG.DEPRECATED_FILENAME`, `CONFIG.DEPRECATED_SHAPE`), so existing projects keep loading until the codemod story lands. The bin adapter unwraps the `orm` section before handing config to command handlers, so the handlers are untouched. **5. `init` scaffolds for the unified CLI.** New projects get `prisma.config.ts` in the engine shape, package scripts that invoke `prisma-cli`, and devDependencies `@prisma/cli@next` + `@prisma/cli-engine` (the config file imports the engine's `defineConfig`). **6. User-facing prose names the bin users actually have.** The engine only substitutes its `{bin}` placeholder in help examples and command redirects, so ~100 hardcoded `prisma-next <cmd>` strings in next-actions, fix suggestions, and init templates now say `prisma-cli`. Telemetry threads the settled exit code through the pipeline. The framework-vocabulary ratchet drops 364 → 308. **7. Docs catch up.** The root README installs `@prisma/cli@next`; the CLI package README describes the engine entry; the style guide, error reference, and e2e-patterns doc describe commander in the past tense; ADR 242 carries a supersession note for the retired bin distribution; ADR 239 records the `CLI.*` error namespace as shared with `@prisma/cli-engine`. ## Operator-review items - **`init`'s devDependency choice**: `@prisma/cli@next` + `@prisma/cli-engine`, scripts on the `prisma-cli` bin. The alternative — the `prisma-next` npm name living on as an rc channel published from the prisma-cli repo — does not exist yet; scaffolding it today would install the stale artifact this repo used to publish. - **The npm `prisma-next` name**: this PR only stops publishing it; deprecating or handing off the name is operator-owned. - **Generated-artifact headers**: emitted artifacts still carry `prisma-next`-flavoured headers. The emitter cannot know which bin invoked it, and changing the header would churn every committed fixture, so they were left alone — flagging for an explicit call. - **Hardcoded `prisma-cli` in remediation strings**: the ~100 next-action/fix strings name the unified bin literally because the engine has no `{bin}` templating outside help/redirects. If the engine grows that affordance, these should switch to it. ## Verification | Check | Result | | --- | --- | | root `pnpm build` | exit 0 | | cli `pnpm typecheck` / `pnpm lint` / `pnpm test` | exit 0 / exit 0 (264 infos) / 113 files, 1410/1410 | | config-loader `pnpm test` | exit 0 — 53/53 | | `pnpm test:integration` (full) | 10 failed files on the loaded full run → triaged: 1 real (a retry-hint assertion behind the prose sweep — fixed), the known machine-local timezone artifact (`issues-28192-pg-historical-dates`, 2 tests), a mongodb-memory-server port collision, and 7 timeout flakes; everything except the timezone artifact passes isolated with `TEST_TIMEOUT_MULTIPLIER=2` (34/34 + 2/2) | | `pnpm fixtures:check` | exit 0, no fixture diffs (after repairing the two cutover leftovers it caught — see the last commit) | | `pnpm lint:deps` | exit 0 | | `node scripts/lint-framework-vocabulary.mjs` | exit 0 (count 308 = threshold) | The cutover's divergence record and porting ledger live in the prisma-cli repo on branch `s5-cutover-divergences` (`.drive/projects/prisma-cli-v8/assets/s2/parity-divergences-s5-cutover.md`, `assets/s5/cutover-ledger.md`). ## Alternatives considered - **Keep publishing `prisma-next` as a thin shim over the engine bin.** Rejected: it would ship a second binary with identical behaviour under a stale name, while the rollout plan's happy path is the unified CLI. - **Port the stdout-formatting tests onto the engine renderer instead of deleting them.** Rejected: the renderer belongs to the engine and is tested there; re-asserting its output here would pin another repo's presentation. - **A hard cut on config filenames — engine semantics only, no fallback.** Rejected for this repo's own users: the deprecation path keeps every existing project loading (with a warning) until the codemod story lands post-rc. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Signed-off-by: willbot <w.a.madden+machine@gmail.com> Signed-off-by: Will Madden <madden@prisma.io> Co-authored-by: Claude Fable 5 <noreply@anthropic.com> | 1 个月前 | |
feat: implement CLI telemetry Implements Phase 1 CLI telemetry for Prisma Next: an explicit opt-in consent path in `prisma-next init`, a detached sender process that posts anonymous command-start events without blocking CLI work, and a Bun/Postgres backend that stores accepted events through Prisma Next itself. Deliberately out of scope: crash/error reporting. That path has different privacy and lifecycle constraints and is deferred to a separate Phase 2. ## At a glance ```ts const payload: ParentToSenderPayload = { installationId: config.installationId, version: inputs.version, command: sanitised.command, flags: sanitised.flags, databaseTarget: inputs.databaseTarget, extensions: inputs.extensions, projectRoot: inputs.projectRoot, endpoint: resolveTelemetryEndpoint(env), }; ``` Telemetry starts from a sanitized parent-process payload — command and flag names only, no positional args or flag values — and a detached child enriches and sends it. ## How it fits together - **Backend storage is contract-first.** `apps/telemetry-backend/src/prisma/contract.prisma` defines a single `TelemetryEvent` model, with committed `contract.json` / `contract.d.ts` artifacts and migration outputs so the ingest service dogfoods Prisma Next. - **The ingest API is small and forward-compatible.** `POST /events` requires the stable core fields, defaults omitted optional fields to `null` / `[]`, drops unknown future keys, enforces request-size limits, and rate-limits callers before INSERT. - **User consent is per-user and default-off.** `@prisma-next/cli-telemetry` stores `enableTelemetry` and a random v4 `installationId` under the user config directory; env overrides and CI suppress telemetry without mutating that file. - **The CLI fires at command start.** A `preAction` hook resolves CI/env/user gates first, then loads only the telemetry-safe pieces of project config, sanitizes Commander metadata, and forks a detached sender. - **The child owns all I/O.** The sender enriches the payload with runtime, package manager, TypeScript version, OS/arch, and best-effort agent markers, POSTs with a hard timeout, and exits 0 while swallowing failures. ## Behavior changes Adds the telemetry backend ingest service. Accepts `POST /events`, validates the payload, enforces 32 KiB request limits and per-IP rate limiting, then inserts via Prisma Next. - Implementation: `apps/telemetry-backend/src/handler.ts`, `apps/telemetry-backend/src/schema.ts`, `apps/telemetry-backend/src/rate-limiter.ts` - Tests: `apps/telemetry-backend/test/handler.test.ts`, `apps/telemetry-backend/test/rate-limit.handler.test.ts` Adds default-off, opt-in telemetry consent. `init` asks a final interactive consent question only when prompting is allowed, `--yes` is not auto-accepting, CI/env overrides are absent, and no stored answer exists. - Implementation: `packages/1-framework/3-tooling/cli/src/commands/init/inputs.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/user-config.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/gating.ts` - Tests: `packages/1-framework/3-tooling/cli/test/commands/init/consent-prompt.test.ts`, `packages/1-framework/3-tooling/cli-telemetry/test/gating.test.ts` Adds detached command-start delivery. The CLI preAction hook forks the sender, disconnects/unrefs it, and keeps telemetry failures out of the parent command's stdout/stderr and exit path. - Implementation: `packages/1-framework/3-tooling/cli/src/cli.ts`, `packages/1-framework/3-tooling/cli/src/utils/telemetry.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/spawn.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/sender.ts` - Tests: `packages/1-framework/3-tooling/cli/test/utils/telemetry.test.ts`, `packages/1-framework/3-tooling/cli-telemetry/test/spawn.test.ts`, `packages/1-framework/3-tooling/cli-telemetry/test/integration.test.ts` Adds sanitization and enrichment without user values. Events include command name, user-supplied long flag names, runtime/package metadata, target, extensions, and agent markers; they intentionally exclude positionals and flag values. - Implementation: `packages/1-framework/3-tooling/cli-telemetry/src/sanitize.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/enrich.ts`, `packages/1-framework/3-tooling/cli-telemetry/src/detect-agent.ts` - Tests: `packages/1-framework/3-tooling/cli-telemetry/test/sanitize.test.ts`, `packages/1-framework/3-tooling/cli-telemetry/test/enrich.test.ts`, `packages/1-framework/3-tooling/cli-telemetry/test/detect-agent.test.ts` ## Compatibility, migration, risk - Telemetry remains off unless the user explicitly opts in; `PRISMA_NEXT_DISABLE_TELEMETRY`, `DO_NOT_TRACK=1`, and CI all suppress it. - The backend wire format is backward-compatible for optional fields and forward-compatible for unknown future fields. - `apps/*` is now part of the workspace, so the telemetry backend participates in install/build/test orchestration. Existing package-layer dependency checks remain scoped to `packages/`. - The production endpoint URL is currently a build-time constant; if Prisma Compute reassigns it, the client constant needs to be updated before release. ## Alternatives considered - **Send telemetry synchronously from the parent process.** Rejected because network failures or slow DNS could affect the CLI UX. - **Use a per-project telemetry setting.** Rejected because one developer's project config should not enroll or opt out teammates. - **Collect crash/error reporting in Phase 1.** Rejected because stack traces and failure lifecycle need separate consent and sanitization rules. Refs TML-2557 Co-authored-by: Alexey Orlenko <alex@aqrln.net> Signed-off-by: Alexey Orlenko <alex@aqrln.net> Signed-off-by: Alexey Orlenko's AI Agent <robot@aqrln.net> | 3 个月前 |
telemetry-backend
A telemetry HTTP service that receives Prisma 8 CLI events, validates them
with arktype, and inserts them into Postgres through Prisma 8 itself
(dogfooded). The production/deploy entrypoint uses Bun.serve; the same
handler can also run behind node:http for repo tests that must not require a
Bun binary. The service is unauthenticated by design — events are anonymous —
and rate-limited at the edge to mitigate abuse.
This package lives under apps/ rather than packages/ because the
backend is a deployable service, not a framework component. It sits
outside the framework domain boundary in architecture.config.json by
construction (the packages glob and lint:deps configuration both
scope to packages/), so it consumes the full Prisma 8 stack without
violating domain layering.
Endpoint
POST /events— accept a JSON event payload.
Responses:
| Status | Meaning |
|---|---|
202 |
Event validated and inserted. |
400 |
Payload was not JSON, missed a required field, or exceeded a field/array schema bound. |
413 |
Content-Length or the streamed body exceeded the 32 KiB request cap. |
404 |
Path other than /events. |
405 |
Method other than POST. |
429 |
Per-IP rate limit exceeded. |
Wire format
The accepted payload shape (described as a TypeScript signature; arktype
enforces the same at runtime in src/schema.ts):
interface TelemetryEventPayload {
installationId: string; // required, non-empty, <= 512 chars
version: string; // required, non-empty, <= 512 chars
command: string; // required, non-empty, <= 512 chars
runtimeName: string; // required, non-empty, <= 512 chars
runtimeVersion: string; // required, non-empty, <= 512 chars
os: string; // required, non-empty, <= 512 chars
arch: string; // required, non-empty, <= 512 chars
flags?: string[]; // defaults to [], each item <= 128 chars; total payload <= 32 KiB
packageManager?: string | null; // defaults to null, string <= 512 chars
databaseTarget?: string | null; // defaults to null, string <= 512 chars
tsVersion?: string | null; // defaults to null, string <= 512 chars
agent?: string | null; // defaults to null, string <= 512 chars
extensions?: string[]; // defaults to [], each item <= 128 chars; total payload <= 32 KiB
}
Missing any required field returns 400 Bad Request. Optional arrays
default to []; optional nullable scalars default to null.
Forward compatibility: any keys outside this shape are silently dropped before persistence — newer clients can introduce fields without a backend update.
Request-size guardrail: requests are capped at 32 KiB. If
Content-Length is present and exceeds the cap, the backend returns
413 Payload Too Large before reading the body. Requests without a
trustworthy Content-Length are still read through the same hard cap,
so chunked or lying clients cannot stream unbounded data.
Configuration
The service is configured exclusively through environment variables:
| Variable | Required | Default | Meaning |
|---|---|---|---|
DATABASE_URL |
yes | — | Postgres connection string (postgres:// or postgresql://). |
PORT |
no | 8080 |
TCP port for the HTTP server. |
RATE_LIMIT_RPM |
no | 120 |
Requests/minute/IP. The token-bucket capacity is set to this value (i.e. it doubles as the burst budget). |
TRUST_FORWARDED_FOR |
no | false |
Set to 1 / true / yes only when the backend sits behind a proxy that strips inbound x-forwarded-for and writes its own (e.g. Prisma Compute). When unset, the per-IP rate-limit key is taken from the socket address, because any direct caller could otherwise set the header to bypass the limit. |
The Postgres schema is the model authored in src/prisma/contract.prisma
(committed in src/prisma/contract.json / contract.d.ts). Use
pnpm db init or any equivalent migration of your choice to create the
telemetry_event table before pointing the service at a database.
Local development
pnpm install
pnpm --filter telemetry-backend emit # refresh contract.json / contract.d.ts
pnpm --filter telemetry-backend test # vitest, spins up @prisma/dev Postgres
pnpm --filter telemetry-backend typecheck
pnpm --filter telemetry-backend lint
To start the Bun server against a Postgres of your choice:
DATABASE_URL=postgres://postgres:postgres@localhost:5433/telemetry \
PORT=8080 \
pnpm --filter telemetry-backend start
For Node-only test harnesses, the equivalent node:http entrypoint is:
DATABASE_URL=postgres://postgres:postgres@localhost:5433/telemetry \
PORT=8080 \
pnpm --filter telemetry-backend start:node
The repository ships a docker-compose.yaml at its root that exposes
Postgres on localhost:5433 for local-dev use.
Deploy hand-off
Deployment goes through Prisma Compute via pnpm run deploy, which
runs scripts/deploy.ts. The script uses @prisma/compute-sdk's
BunBuild strategy to build the package from src/server.ts, archive
and upload it, create a new version, and promote it on the configured
service. The assigned *.prisma.build URL is the build-time constant
the CLI client embeds.
scripts/deploy.ts reads three env vars (in addition to DATABASE_URL,
which is only needed for the migrate step):
| Variable | Required | Meaning |
|---|---|---|
TELEMETRY_DEPLOY_SERVICE_TOKEN |
yes | Prisma Management API token. |
TELEMETRY_DEPLOY_PROJECT_ID |
yes | Prisma Compute project ID. |
TELEMETRY_DEPLOY_SERVICE_ID |
yes | Prisma Compute service ID. |
In CI, the canonical entry point is
.github/workflows/deploy-telemetry-backend.yml,
which on main pushes (and via workflow_dispatch) applies any
pending migrations against the production database with pnpm run migrate and then runs pnpm run deploy against the configured
project/service. All four secrets above are provided by the workflow.
To deploy manually from a developer machine, set the four env vars and
run the same two commands from apps/telemetry-backend/:
DATABASE_URL=<production-postgres-url> \
TELEMETRY_DEPLOY_SERVICE_TOKEN=<token> \
TELEMETRY_DEPLOY_PROJECT_ID=<project-id> \
TELEMETRY_DEPLOY_SERVICE_ID=<service-id> \
pnpm run migrate && pnpm run deploy
Post-deploy verification:
curl -i -X POST https://<url>/events \
-H 'content-type: application/json' \
-d '{"installationId":"smoke-test","version":"0.0.0","command":"smoke","runtimeName":"node","runtimeVersion":"24","os":"linux","arch":"x64"}'
# expect: HTTP/2 202