From 6f000148bf7cecce53f00efa8dd68f4acd873c4e Mon Sep 17 00:00:00 2001 From: willbot Date: Mon, 28 Sep 2026 09:24:23 +0200 Subject: [PATCH 1/2] fix(deps): build orm-toolchain against @prisma/cli-engine 0.6.2, the engine the prisma CLI ships The prisma CLI ships @prisma/cli-engine 0.6.2 from prisma/prisma-cli#313, and its release check refuses a command family built against a different engine: npm would install two engines. @prisma/orm-toolchain 8.0.0-rc.12 peers engine 0.6.1. Every engine pin moves from 0.6.1 to 0.6.2. Engine 0.6.2 substitutes {bin} in next actions, diagnostics, errors, and summary and list blocks, and changes no API the ORM calls, so there are no source changes. pnpm-lock.yaml is not in this commit. It can be refreshed only after 0.6.2 is on npm. Upgrade instructions: upgrade-instructions/pending/engine-pin-moves-to-0-6-2/app/ and upgrade-instructions/pending/engine-pin-moves-to-0-6-2/extension/. Signed-off-by: willbot Signed-off-by: Will Madden Co-Authored-By: Claude Fable 5.1 --- apps/lsp-playground/package.json | 2 +- apps/telemetry-backend/package.json | 2 +- examples/bundle-size/package.json | 2 +- examples/mongo-blog-leaderboard/package.json | 2 +- examples/mongo-demo/package.json | 2 +- examples/multi-extension-monorepo/package.json | 2 +- examples/paradedb-demo/package.json | 2 +- examples/prisma-8-cloudflare-worker/package.json | 2 +- examples/prisma-8-demo-sqlite/package.json | 2 +- examples/prisma-8-demo/package.json | 2 +- examples/prisma-8-postgis-demo/package.json | 2 +- examples/prisma7-adoption/package.json | 2 +- examples/react-router-demo/package.json | 2 +- examples/retail-store/package.json | 2 +- examples/supabase/package.json | 2 +- packages/1-framework/3-tooling/cli/package.json | 4 ++-- .../3-tooling/config-loader/package.json | 4 ++-- packages/3-extensions/paradedb/package.json | 2 +- packages/3-extensions/pgvector/package.json | 2 +- packages/3-extensions/postgis/package.json | 2 +- packages/3-extensions/supabase/package.json | 2 +- .../9-public/@prisma/orm-toolchain/package.json | 2 +- test/e2e/framework/test/fixtures/package.json | 2 +- .../framework/test/sqlite/fixtures/package.json | 2 +- test/integration/package.json | 2 +- .../fixtures/cli/cli-e2e-test-app/package.json | 2 +- .../cli/cli-integration-test-app/package.json | 2 +- .../engine-pin-moves-to-0-6-2/app/instructions.md | 14 ++++++++++++++ .../extension/instructions.md | 14 ++++++++++++++ 29 files changed, 57 insertions(+), 29 deletions(-) create mode 100644 upgrade-instructions/pending/engine-pin-moves-to-0-6-2/app/instructions.md create mode 100644 upgrade-instructions/pending/engine-pin-moves-to-0-6-2/extension/instructions.md diff --git a/apps/lsp-playground/package.json b/apps/lsp-playground/package.json index 6ce4bd904df7..2fb3597b6278 100644 --- a/apps/lsp-playground/package.json +++ b/apps/lsp-playground/package.json @@ -35,7 +35,7 @@ "ws": "^8.21.2" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@types/node": "catalog:", "@types/ws": "^8.5.13", diff --git a/apps/telemetry-backend/package.json b/apps/telemetry-backend/package.json index 274709f7c50e..85b3bf278ca4 100644 --- a/apps/telemetry-backend/package.json +++ b/apps/telemetry-backend/package.json @@ -27,7 +27,7 @@ "evlog": "^2.24.0" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@prisma/compute-sdk": "^0.43.0", "@prisma/management-api-sdk": "^1.76.0", "@repo/test-utils": "workspace:8.0.0-rc.12", diff --git a/examples/bundle-size/package.json b/examples/bundle-size/package.json index 6c412e8c2248..a5ba8badf60e 100644 --- a/examples/bundle-size/package.json +++ b/examples/bundle-size/package.json @@ -28,7 +28,7 @@ "pg": "catalog:" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@prisma/dev": "catalog:", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", diff --git a/examples/mongo-blog-leaderboard/package.json b/examples/mongo-blog-leaderboard/package.json index 9016cc519174..d23460815857 100644 --- a/examples/mongo-blog-leaderboard/package.json +++ b/examples/mongo-blog-leaderboard/package.json @@ -19,7 +19,7 @@ "mongodb": "catalog:" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@types/node": "catalog:", "mongodb-memory-server": "catalog:", diff --git a/examples/mongo-demo/package.json b/examples/mongo-demo/package.json index adc407321220..b7e41423b87c 100644 --- a/examples/mongo-demo/package.json +++ b/examples/mongo-demo/package.json @@ -24,7 +24,7 @@ "react-dom": "^19.2.8" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@types/node": "catalog:", diff --git a/examples/multi-extension-monorepo/package.json b/examples/multi-extension-monorepo/package.json index 2e8cd1a7f13f..9f111d4d7965 100644 --- a/examples/multi-extension-monorepo/package.json +++ b/examples/multi-extension-monorepo/package.json @@ -18,7 +18,7 @@ "@prisma/orm-postgres": "workspace:8.0.0-rc.12" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@types/node": "catalog:", diff --git a/examples/paradedb-demo/package.json b/examples/paradedb-demo/package.json index 3612b146e002..f71d8bee9adf 100644 --- a/examples/paradedb-demo/package.json +++ b/examples/paradedb-demo/package.json @@ -25,7 +25,7 @@ "pg": "catalog:" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@types/node": "catalog:", diff --git a/examples/prisma-8-cloudflare-worker/package.json b/examples/prisma-8-cloudflare-worker/package.json index 758eea2e9c94..f9a80165c666 100644 --- a/examples/prisma-8-cloudflare-worker/package.json +++ b/examples/prisma-8-cloudflare-worker/package.json @@ -29,7 +29,7 @@ "devDependencies": { "@cloudflare/vitest-pool-workers": "0.20.3", "@cloudflare/workers-types": "5.20260804.1", - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@types/node": "catalog:", "@types/pg": "catalog:", diff --git a/examples/prisma-8-demo-sqlite/package.json b/examples/prisma-8-demo-sqlite/package.json index cb4e35ab77f2..36bcbc8ec22c 100644 --- a/examples/prisma-8-demo-sqlite/package.json +++ b/examples/prisma-8-demo-sqlite/package.json @@ -20,7 +20,7 @@ "dotenv": "^17.4.2" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@types/node": "catalog:", "tsx": "catalog:", diff --git a/examples/prisma-8-demo/package.json b/examples/prisma-8-demo/package.json index 7a28b79960b8..ed08525b0f0c 100644 --- a/examples/prisma-8-demo/package.json +++ b/examples/prisma-8-demo/package.json @@ -32,7 +32,7 @@ "react-dom": "^19.2.8" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@prisma/dev": "catalog:", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", diff --git a/examples/prisma-8-postgis-demo/package.json b/examples/prisma-8-postgis-demo/package.json index 50b8844942da..88e61a4646f3 100644 --- a/examples/prisma-8-postgis-demo/package.json +++ b/examples/prisma-8-postgis-demo/package.json @@ -33,7 +33,7 @@ "react-leaflet": "^5.0.0" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@types/leaflet": "^1.9.22", diff --git a/examples/prisma7-adoption/package.json b/examples/prisma7-adoption/package.json index 7c2543187697..69ca62a1e86a 100644 --- a/examples/prisma7-adoption/package.json +++ b/examples/prisma7-adoption/package.json @@ -29,7 +29,7 @@ "temporal-polyfill": "^1.0.4" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@prisma/dev": "catalog:", "@prisma/prisma7": "7.10.0", "@repo/test-utils": "workspace:8.0.0-rc.12", diff --git a/examples/react-router-demo/package.json b/examples/react-router-demo/package.json index 43c577a5dd82..32bfe457ebd0 100644 --- a/examples/react-router-demo/package.json +++ b/examples/react-router-demo/package.json @@ -30,7 +30,7 @@ "react-router": "^8.1.0" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@prisma/dev": "catalog:", "@react-router/dev": "^8.1.0", "@repo/test-utils": "workspace:8.0.0-rc.12", diff --git a/examples/retail-store/package.json b/examples/retail-store/package.json index 595aae239564..4e4745953520 100644 --- a/examples/retail-store/package.json +++ b/examples/retail-store/package.json @@ -39,7 +39,7 @@ "tailwindcss": "^4.3.3" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@types/node": "catalog:", diff --git a/examples/supabase/package.json b/examples/supabase/package.json index b4c2df080eb9..08df18faf4c5 100644 --- a/examples/supabase/package.json +++ b/examples/supabase/package.json @@ -18,7 +18,7 @@ "pg": "catalog:" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@types/node": "catalog:", diff --git a/packages/1-framework/3-tooling/cli/package.json b/packages/1-framework/3-tooling/cli/package.json index b9e8ce8ca096..fb503cf84968 100644 --- a/packages/1-framework/3-tooling/cli/package.json +++ b/packages/1-framework/3-tooling/cli/package.json @@ -52,7 +52,7 @@ "@internal/sql-contract-ts": "workspace:8.0.0-rc.12", "@internal/sql-operations": "workspace:8.0.0-rc.12", "@internal/sql-runtime": "workspace:8.0.0-rc.12", - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@repo/tsdown": "workspace:8.0.0-rc.12", @@ -62,7 +62,7 @@ "vitest": "catalog:" }, "peerDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "typescript": ">=5.9" }, "peerDependenciesMeta": { diff --git a/packages/1-framework/3-tooling/config-loader/package.json b/packages/1-framework/3-tooling/config-loader/package.json index ce418e3f536a..2e5f29aedd4b 100644 --- a/packages/1-framework/3-tooling/config-loader/package.json +++ b/packages/1-framework/3-tooling/config-loader/package.json @@ -26,7 +26,7 @@ "tinyglobby": "catalog:" }, "devDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@repo/tsdown": "workspace:8.0.0-rc.12", @@ -36,7 +36,7 @@ "vitest": "catalog:" }, "peerDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "typescript": ">=5.9" }, "peerDependenciesMeta": { diff --git a/packages/3-extensions/paradedb/package.json b/packages/3-extensions/paradedb/package.json index 1fe4516edc9c..8f4e5d993aae 100644 --- a/packages/3-extensions/paradedb/package.json +++ b/packages/3-extensions/paradedb/package.json @@ -34,7 +34,7 @@ "@internal/operations": "workspace:8.0.0-rc.12", "@internal/sql-contract-ts": "workspace:8.0.0-rc.12", "@internal/target-postgres": "workspace:8.0.0-rc.12", - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@repo/tsdown": "workspace:8.0.0-rc.12", diff --git a/packages/3-extensions/pgvector/package.json b/packages/3-extensions/pgvector/package.json index 22dde702b2c2..2153cd8a7dbd 100644 --- a/packages/3-extensions/pgvector/package.json +++ b/packages/3-extensions/pgvector/package.json @@ -39,7 +39,7 @@ "@internal/postgres": "workspace:8.0.0-rc.12", "@internal/postgres-codec-testkit": "workspace:8.0.0-rc.12", "@internal/sql-contract-ts": "workspace:8.0.0-rc.12", - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@repo/tsdown": "workspace:8.0.0-rc.12", diff --git a/packages/3-extensions/postgis/package.json b/packages/3-extensions/postgis/package.json index ceda9fe0b90d..efc8b266749d 100644 --- a/packages/3-extensions/postgis/package.json +++ b/packages/3-extensions/postgis/package.json @@ -37,7 +37,7 @@ "@internal/operations": "workspace:8.0.0-rc.12", "@internal/postgres": "workspace:8.0.0-rc.12", "@internal/sql-contract-ts": "workspace:8.0.0-rc.12", - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@repo/tsdown": "workspace:8.0.0-rc.12", diff --git a/packages/3-extensions/supabase/package.json b/packages/3-extensions/supabase/package.json index cda1702cf4d8..4aaa9efa4e2a 100644 --- a/packages/3-extensions/supabase/package.json +++ b/packages/3-extensions/supabase/package.json @@ -48,7 +48,7 @@ "@internal/operations": "workspace:8.0.0-rc.12", "@internal/psl-printer": "workspace:8.0.0-rc.12", "@internal/sql-contract-psl": "workspace:8.0.0-rc.12", - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@repo/tsdown": "workspace:8.0.0-rc.12", diff --git a/packages/9-public/@prisma/orm-toolchain/package.json b/packages/9-public/@prisma/orm-toolchain/package.json index 866d3bd0ebbd..e5adc474efe3 100644 --- a/packages/9-public/@prisma/orm-toolchain/package.json +++ b/packages/9-public/@prisma/orm-toolchain/package.json @@ -49,7 +49,7 @@ "typescript": "catalog:" }, "peerDependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "typescript": ">=5.9", "vite": "^7.0.0 || ^8.0.0" }, diff --git a/test/e2e/framework/test/fixtures/package.json b/test/e2e/framework/test/fixtures/package.json index a63ae2a864b8..e42866cb64d2 100644 --- a/test/e2e/framework/test/fixtures/package.json +++ b/test/e2e/framework/test/fixtures/package.json @@ -5,7 +5,7 @@ "version": "8.0.0-rc.12", "description": "The Postgres fixture of the e2e suite. Its own manifest because emission reads the nearest one to decide which package names generated files import, and this suite exercises two databases whose halves must not name each other's facade.", "dependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@prisma/orm-extension-arktype-json": "workspace:8.0.0-rc.12", "@prisma/orm-extension-pgvector": "workspace:8.0.0-rc.12", "@prisma/orm-postgres": "workspace:8.0.0-rc.12", diff --git a/test/e2e/framework/test/sqlite/fixtures/package.json b/test/e2e/framework/test/sqlite/fixtures/package.json index 14b5c343b3d8..f5b410b5a67b 100644 --- a/test/e2e/framework/test/sqlite/fixtures/package.json +++ b/test/e2e/framework/test/sqlite/fixtures/package.json @@ -5,7 +5,7 @@ "version": "8.0.0-rc.12", "description": "The SQLite fixture of the e2e suite. Its own manifest because emission reads the nearest one to decide which package names generated files import, and this suite exercises two databases whose halves must not name each other's facade.", "dependencies": { - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@prisma/orm-sqlite": "workspace:8.0.0-rc.12" } } diff --git a/test/integration/package.json b/test/integration/package.json index a83c1f66b5fe..c3778cc7cd13 100644 --- a/test/integration/package.json +++ b/test/integration/package.json @@ -82,7 +82,7 @@ "@internal/middleware-cache": "workspace:8.0.0-rc.12", "@internal/mongo-lowering": "workspace:8.0.0-rc.12", "@internal/publish-surface": "workspace:8.0.0-rc.12", - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@repo/test-utils": "workspace:8.0.0-rc.12", "@repo/tsconfig": "workspace:8.0.0-rc.12", "@repo/tsdown": "workspace:8.0.0-rc.12", diff --git a/test/integration/test/fixtures/cli/cli-e2e-test-app/package.json b/test/integration/test/fixtures/cli/cli-e2e-test-app/package.json index dc6177629c09..30426a99979d 100644 --- a/test/integration/test/fixtures/cli/cli-e2e-test-app/package.json +++ b/test/integration/test/fixtures/cli/cli-e2e-test-app/package.json @@ -19,7 +19,7 @@ "@internal/target-mongo": "workspace:8.0.0-rc.12", "@internal/target-postgres": "workspace:8.0.0-rc.12", "@internal/utils": "workspace:8.0.0-rc.12", - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@prisma/orm-extension-pgvector": "workspace:8.0.0-rc.12", "@prisma/orm-mongo": "workspace:8.0.0-rc.12", "@prisma/orm-postgres": "workspace:8.0.0-rc.12", diff --git a/test/integration/test/fixtures/cli/cli-integration-test-app/package.json b/test/integration/test/fixtures/cli/cli-integration-test-app/package.json index 7a837efdc12e..dac9e053d0be 100644 --- a/test/integration/test/fixtures/cli/cli-integration-test-app/package.json +++ b/test/integration/test/fixtures/cli/cli-integration-test-app/package.json @@ -20,7 +20,7 @@ "@internal/target-mongo": "workspace:8.0.0-rc.12", "@internal/target-postgres": "workspace:8.0.0-rc.12", "@internal/utils": "workspace:8.0.0-rc.12", - "@prisma/cli-engine": "0.6.1", + "@prisma/cli-engine": "0.6.2", "@prisma/orm-extension-pgvector": "workspace:8.0.0-rc.12", "@prisma/orm-mongo": "workspace:8.0.0-rc.12", "@prisma/orm-postgres": "workspace:8.0.0-rc.12", diff --git a/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/app/instructions.md b/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/app/instructions.md new file mode 100644 index 000000000000..4bb294ded849 --- /dev/null +++ b/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/app/instructions.md @@ -0,0 +1,14 @@ +--- +changes: + - id: engine-pin-moves-to-0-6-2 + summary: | + The toolchain now requires `@prisma/cli-engine@0.6.2` (up from 0.6.1). A project that pins `@prisma/cli-engine` itself must move the pin to `0.6.2`. + detection: + glob: "**/package.json" + contains: + - '"@prisma/cli-engine": "0.6.1"' +--- + +## `engine-pin-moves-to-0-6-2` + +For every `package.json` matched by `detection`, change the `@prisma/cli-engine` version from `0.6.1` to `0.6.2` and reinstall. Projects assembled by the `prisma` CLI resolve the engine automatically. diff --git a/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/extension/instructions.md b/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/extension/instructions.md new file mode 100644 index 000000000000..55faf3ea3c14 --- /dev/null +++ b/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/extension/instructions.md @@ -0,0 +1,14 @@ +--- +changes: + - id: engine-pin-moves-to-0-6-2 + summary: | + The toolchain now peers `@prisma/cli-engine@0.6.2` (up from 0.6.1). An extension package that pins `@prisma/cli-engine` for its tests or tooling must move the pin to `0.6.2`. + detection: + glob: "**/package.json" + contains: + - '"@prisma/cli-engine": "0.6.1"' +--- + +## `engine-pin-moves-to-0-6-2` + +For every `package.json` matched by `detection`, change the `@prisma/cli-engine` version from `0.6.1` to `0.6.2` and reinstall. From ffd1e2994625cde8bc98a6960672a278447c4f79 Mon Sep 17 00:00:00 2001 From: willbot Date: Tue, 29 Sep 2026 14:06:15 +0200 Subject: [PATCH 2/2] test(cli): expect the CLI name where engine 0.6.2 replaces {bin} Engine 0.6.2 replaces {bin} with the name of the running CLI in next actions, diagnostics, errors, and summary and list blocks. The tests that run a command through the engine now expect `prisma-test`, the name the test CLI uses. Tests of the error factories still expect {bin}, because the libraries keep writing the placeholder. The upgrade instructions for the engine pin now say what a reader sees change. Signed-off-by: willbot Signed-off-by: Will Madden Co-Authored-By: Claude Fable 5.1 --- .../cli/test/orm/contract-print.test.ts | 30 +++++++++++++++---- .../3-tooling/cli/test/orm/db-init.test.ts | 4 +-- .../3-tooling/cli/test/orm/db-sign.test.ts | 4 +-- .../3-tooling/cli/test/orm/db-update.test.ts | 4 +-- .../3-tooling/cli/test/orm/db-verify.test.ts | 2 +- .../cli/test/orm/define-command.test.ts | 2 +- .../3-tooling/cli/test/orm/migrate.test.ts | 2 +- .../cli/test/orm/migration-plan.test.ts | 2 +- .../cli/test/orm/migration-status.test.ts | 2 +- .../3-tooling/cli/test/orm/ref-set.test.ts | 2 +- ...marker-read-errors-legacy-init.e2e.test.ts | 2 +- .../migration-status-diagnostics.e2e.test.ts | 8 ++--- .../sign-the-database.e2e.test.ts | 2 +- .../test/cli.db-verify.e2e.test.ts | 2 +- .../cli.migrate-external-space.e2e.test.ts | 8 ++--- .../test/marker-read-errors.e2e.test.ts | 2 +- .../app/instructions.md | 4 ++- .../extension/instructions.md | 4 ++- 18 files changed, 55 insertions(+), 31 deletions(-) diff --git a/packages/1-framework/3-tooling/cli/test/orm/contract-print.test.ts b/packages/1-framework/3-tooling/cli/test/orm/contract-print.test.ts index ceaebddc78b9..079b4bc5ceef 100644 --- a/packages/1-framework/3-tooling/cli/test/orm/contract-print.test.ts +++ b/packages/1-framework/3-tooling/cli/test/orm/contract-print.test.ts @@ -39,7 +39,11 @@ describe('contract print', () => { label: 'Write the PSL to a file with --output , then point contract in prisma.config.ts at that file', }, - { kind: 'run-command', label: 'Emit the printed contract', command: '{bin} contract emit' }, + { + kind: 'run-command', + label: 'Emit the printed contract', + command: 'prisma-test contract emit', + }, ]); expect(await readdir(dir)).toEqual([]); }); @@ -215,7 +219,11 @@ describe('contract print', () => { kind: 'user-choice', label: 'Point contract in prisma.config.ts at generated/contract.prisma', }, - { kind: 'run-command', label: 'Emit the printed contract', command: '{bin} contract emit' }, + { + kind: 'run-command', + label: 'Emit the printed contract', + command: 'prisma-test contract emit', + }, ]); expect(run.presented?.presentation.stdout).toEqual([]); expect(stripAnsi(run.stderr)).toContain('Contract written to generated/contract.prisma'); @@ -250,7 +258,11 @@ describe('contract print', () => { label: "Point contract in prisma.config.ts at generated/contract.prisma, through a PSL source that sets defaultControlPolicy: 'external'", }, - { kind: 'run-command', label: 'Emit the printed contract', command: '{bin} contract emit' }, + { + kind: 'run-command', + label: 'Emit the printed contract', + command: 'prisma-test contract emit', + }, ]); }); @@ -315,7 +327,11 @@ describe('contract print', () => { label: "With contract: './prisma/contract.prisma' and no output in prisma.config.ts, contract emit writes prisma/contract.json and prisma/contract.d.ts, not prisma/schema.json and prisma/schema.d.ts", }, - { kind: 'run-command', label: 'Emit the printed contract', command: '{bin} contract emit' }, + { + kind: 'run-command', + label: 'Emit the printed contract', + command: 'prisma-test contract emit', + }, ]); }); @@ -347,7 +363,11 @@ describe('contract print', () => { label: "With contract: './src/prisma/contract.prisma' and no output in prisma.config.ts, contract emit writes src/prisma/contract.json and src/prisma/contract.d.ts, not prisma/schema.json and prisma/schema.d.ts", }, - { kind: 'run-command', label: 'Emit the printed contract', command: '{bin} contract emit' }, + { + kind: 'run-command', + label: 'Emit the printed contract', + command: 'prisma-test contract emit', + }, ]); }); diff --git a/packages/1-framework/3-tooling/cli/test/orm/db-init.test.ts b/packages/1-framework/3-tooling/cli/test/orm/db-init.test.ts index 13433438f690..ca090cf6f956 100644 --- a/packages/1-framework/3-tooling/cli/test/orm/db-init.test.ts +++ b/packages/1-framework/3-tooling/cli/test/orm/db-init.test.ts @@ -256,7 +256,7 @@ describe('db init', () => { { kind: 'run-command', label: 'Confirm the space is up to date', - command: '{bin} migration status', + command: 'prisma-test migration status', }, ]); }); @@ -314,7 +314,7 @@ describe('db init', () => { { kind: 'run-command', label: 'Apply the planned operations', - command: '{bin} db init', + command: 'prisma-test db init', }, ]); }); diff --git a/packages/1-framework/3-tooling/cli/test/orm/db-sign.test.ts b/packages/1-framework/3-tooling/cli/test/orm/db-sign.test.ts index a7031e9abd9c..ac4c17214281 100644 --- a/packages/1-framework/3-tooling/cli/test/orm/db-sign.test.ts +++ b/packages/1-framework/3-tooling/cli/test/orm/db-sign.test.ts @@ -153,7 +153,7 @@ describe('db sign', () => { { kind: 'run-command', label: 'Change the database to match the contract, then sign again', - command: '{bin} db update', + command: 'prisma-test db update', }, { kind: 'user-choice', @@ -177,7 +177,7 @@ describe('db sign', () => { { kind: 'run-command', label: 'Change the database to match the contract, then sign again', - command: '{bin} db update --to "staging"', + command: 'prisma-test db update --to "staging"', }, { kind: 'user-choice', diff --git a/packages/1-framework/3-tooling/cli/test/orm/db-update.test.ts b/packages/1-framework/3-tooling/cli/test/orm/db-update.test.ts index 1de2298172dd..c29736647f53 100644 --- a/packages/1-framework/3-tooling/cli/test/orm/db-update.test.ts +++ b/packages/1-framework/3-tooling/cli/test/orm/db-update.test.ts @@ -285,7 +285,7 @@ describe('db update', () => { { kind: 'run-command', label: 'Confirm the space is up to date', - command: '{bin} migration status', + command: 'prisma-test migration status', }, ]); }); @@ -326,7 +326,7 @@ describe('db update', () => { { kind: 'run-command', label: 'Apply the planned operations', - command: '{bin} db update', + command: 'prisma-test db update', }, ]); }); diff --git a/packages/1-framework/3-tooling/cli/test/orm/db-verify.test.ts b/packages/1-framework/3-tooling/cli/test/orm/db-verify.test.ts index 8d5ca122a8a9..76ff1e23eb5c 100644 --- a/packages/1-framework/3-tooling/cli/test/orm/db-verify.test.ts +++ b/packages/1-framework/3-tooling/cli/test/orm/db-verify.test.ts @@ -480,7 +480,7 @@ describe('db verify', () => { { kind: 'run-command', label: 'Change the database to match the contract, then verify again', - command: '{bin} db update', + command: 'prisma-test db update', }, { kind: 'user-choice', diff --git a/packages/1-framework/3-tooling/cli/test/orm/define-command.test.ts b/packages/1-framework/3-tooling/cli/test/orm/define-command.test.ts index dcd06c9a8af3..2cd5b0b9201a 100644 --- a/packages/1-framework/3-tooling/cli/test/orm/define-command.test.ts +++ b/packages/1-framework/3-tooling/cli/test/orm/define-command.test.ts @@ -55,7 +55,7 @@ describe('defineOrmCommand', () => { const envelope = erroredEnvelope(run); expect(envelope.nextActions).toEqual([ - { kind: 'user-choice', label: 'Run `{bin} migration list` to see every space.' }, + { kind: 'user-choice', label: 'Run `prisma-test migration list` to see every space.' }, ]); expect(envelope.error).not.toHaveProperty('fix'); }); diff --git a/packages/1-framework/3-tooling/cli/test/orm/migrate.test.ts b/packages/1-framework/3-tooling/cli/test/orm/migrate.test.ts index 6b137fb91f30..16431f6c4e9a 100644 --- a/packages/1-framework/3-tooling/cli/test/orm/migrate.test.ts +++ b/packages/1-framework/3-tooling/cli/test/orm/migrate.test.ts @@ -341,7 +341,7 @@ describe('migrate', () => { { kind: 'run-command', label: 'Check every space against the database', - command: '{bin} migration status', + command: 'prisma-test migration status', }, ]); }); diff --git a/packages/1-framework/3-tooling/cli/test/orm/migration-plan.test.ts b/packages/1-framework/3-tooling/cli/test/orm/migration-plan.test.ts index 9c8cff15dec5..d2a67acd437e 100644 --- a/packages/1-framework/3-tooling/cli/test/orm/migration-plan.test.ts +++ b/packages/1-framework/3-tooling/cli/test/orm/migration-plan.test.ts @@ -234,7 +234,7 @@ describe('migration plan', () => { expect(run.presented?.presentation.next).toEqual([ { kind: 'edit-file', label: `Review ${dir}` }, - { kind: 'run-command', label: 'Apply the migration', command: '{bin} db migrate' }, + { kind: 'run-command', label: 'Apply the migration', command: 'prisma-test db migrate' }, ]); }); diff --git a/packages/1-framework/3-tooling/cli/test/orm/migration-status.test.ts b/packages/1-framework/3-tooling/cli/test/orm/migration-status.test.ts index 82f8c912e0d2..610a3f76e76f 100644 --- a/packages/1-framework/3-tooling/cli/test/orm/migration-status.test.ts +++ b/packages/1-framework/3-tooling/cli/test/orm/migration-status.test.ts @@ -300,7 +300,7 @@ describe('migration status', () => { expect(run.presented?.presentation.human.at(-1)).toEqual({ kind: 'summary', status: 'warn', - text: `1 pending — run \`{bin} db migrate --to ${HASH_HEAD.slice(0, 12)}\``, + text: `1 pending — run \`prisma-test db migrate --to ${HASH_HEAD.slice(0, 12)}\``, }); }); diff --git a/packages/1-framework/3-tooling/cli/test/orm/ref-set.test.ts b/packages/1-framework/3-tooling/cli/test/orm/ref-set.test.ts index ce624ee72c67..2c49dad0ba24 100644 --- a/packages/1-framework/3-tooling/cli/test/orm/ref-set.test.ts +++ b/packages/1-framework/3-tooling/cli/test/orm/ref-set.test.ts @@ -205,7 +205,7 @@ describe('ref set', () => { expect(envelope).toMatchObject({ ok: false, error: { code: 'MIGRATION.HASH_NOT_IN_GRAPH', why: expect.stringContaining('empty') }, - nextActions: [{ kind: 'run-command', command: '{bin} migration plan' }], + nextActions: [{ kind: 'run-command', command: 'prisma-test migration plan' }], }); }); diff --git a/test/integration/test/cli-journeys/marker-read-errors-legacy-init.e2e.test.ts b/test/integration/test/cli-journeys/marker-read-errors-legacy-init.e2e.test.ts index e16d92fd6f78..5770a03028fc 100644 --- a/test/integration/test/cli-journeys/marker-read-errors-legacy-init.e2e.test.ts +++ b/test/integration/test/cli-journeys/marker-read-errors-legacy-init.e2e.test.ts @@ -57,7 +57,7 @@ withTempDir(({ createTempDir }) => { expect.objectContaining({ kind: 'run-command', label: 'Reinitialise the marker table from a clean baseline', - command: '{bin} db init', + command: 'prisma-test db init', }), ); }, diff --git a/test/integration/test/cli-journeys/migration-status-diagnostics.e2e.test.ts b/test/integration/test/cli-journeys/migration-status-diagnostics.e2e.test.ts index 24d277b2d296..47f44075781d 100644 --- a/test/integration/test/cli-journeys/migration-status-diagnostics.e2e.test.ts +++ b/test/integration/test/cli-journeys/migration-status-diagnostics.e2e.test.ts @@ -124,7 +124,7 @@ withTempDir(({ createTempDir }) => { expect(status.exitCode).toBe(0); expect(out).toMatch(/pending/); - expect(out).toContain('{bin} db migrate'); + expect(out).toContain('prisma-test db migrate'); }, timeouts.spinUpPpgDev, ); @@ -207,7 +207,7 @@ withTempDir(({ createTempDir }) => { expect(status.exitCode).toBe(0); expect(out).toMatch(/1 pending/); - expect(out).toContain('{bin} db migrate'); + expect(out).toContain('prisma-test db migrate'); }, timeouts.spinUpPpgDev, ); @@ -281,7 +281,7 @@ withTempDir(({ createTempDir }) => { expect(status.exitCode).toBe(0); expect(out).toContain('@contract'); expect(out).toContain("to the application's contract"); - expect(out).toContain('{bin} migration plan --name'); + expect(out).toContain('prisma-test migration plan --name'); }, timeouts.spinUpPpgDev, ); @@ -574,7 +574,7 @@ withTempDir(({ createTempDir }) => { expect(status.exitCode).toBe(0); expect(out).toContain('No migration path from the database state'); expect(out).toContain('via `production`'); - expect(out).toContain('{bin} migration plan'); + expect(out).toContain('prisma-test migration plan'); }, timeouts.spinUpPpgDev, ); diff --git a/test/integration/test/cli-journeys/sign-the-database.e2e.test.ts b/test/integration/test/cli-journeys/sign-the-database.e2e.test.ts index 943b75d19073..6efa78f0135d 100644 --- a/test/integration/test/cli-journeys/sign-the-database.e2e.test.ts +++ b/test/integration/test/cli-journeys/sign-the-database.e2e.test.ts @@ -124,7 +124,7 @@ describe('sign a database this toolchain has never seen, then transition to wire { kind: 'run-command', label: 'Change the database to match the contract, then sign again', - command: '{bin} db update', + command: 'prisma-test db update', }, { kind: 'user-choice', diff --git a/test/integration/test/cli.db-verify.e2e.test.ts b/test/integration/test/cli.db-verify.e2e.test.ts index 82ce520ab590..21efc4e913ea 100644 --- a/test/integration/test/cli.db-verify.e2e.test.ts +++ b/test/integration/test/cli.db-verify.e2e.test.ts @@ -480,7 +480,7 @@ withTempDir(({ createTempDir }) => { nextActions: expect.arrayContaining([ expect.objectContaining({ label: expect.stringContaining( - 'Run `{bin} db verify --schema-only --strict --db `', + 'Run `prisma-test db verify --schema-only --strict --db `', ), }), ]), diff --git a/test/integration/test/cli.migrate-external-space.e2e.test.ts b/test/integration/test/cli.migrate-external-space.e2e.test.ts index 86b3ce185f66..a4f7df084fc3 100644 --- a/test/integration/test/cli.migrate-external-space.e2e.test.ts +++ b/test/integration/test/cli.migrate-external-space.e2e.test.ts @@ -201,15 +201,15 @@ withTempDir(({ createTempDir }) => { expect(command).not.toMatch(/--to [0-9a-f]{64}/); } expect(remediationCommands).toEqual([ - '{bin} migration plan --name ', - '{bin} db migrate', + 'prisma-test migration plan --name ', + 'prisma-test db migrate', ]); // Execute the presented remediation: derive each command's argv from // the action text itself, substituting the placeholder. const [planCommand, migrateCommand] = remediationCommands; const planArgs = (planCommand ?? '') - .replace(/^\{bin\} migration plan\s*/, '') + .replace(/^prisma-test migration plan\s*/, '') .replaceAll('', 'initial') .split(/\s+/) .filter((arg) => arg.length > 0); @@ -217,7 +217,7 @@ withTempDir(({ createTempDir }) => { expect(plan.exitCode).toBe(0); const migrateArgs = (migrateCommand ?? '') - .replace(/^\{bin\} db migrate\s*/, '') + .replace(/^prisma-test db migrate\s*/, '') .split(/\s+/) .filter((arg) => arg.length > 0); const apply = await runMigrate(project, [...migrateArgs, '--json']); diff --git a/test/integration/test/marker-read-errors.e2e.test.ts b/test/integration/test/marker-read-errors.e2e.test.ts index 664b661afaa0..035cd7bf1d92 100644 --- a/test/integration/test/marker-read-errors.e2e.test.ts +++ b/test/integration/test/marker-read-errors.e2e.test.ts @@ -52,7 +52,7 @@ withTempDir(({ createTempDir }) => { why: expect.stringContaining('Invalid contract marker row'), }, }); - expect(JSON.stringify(envelope)).toContain('{bin} db sign --db '); + expect(JSON.stringify(envelope)).toContain('prisma-test db sign --db '); expect(envelope).not.toHaveProperty('fix'); }, timeouts.spinUpPpgDev, diff --git a/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/app/instructions.md b/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/app/instructions.md index 4bb294ded849..ded7c76a6356 100644 --- a/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/app/instructions.md +++ b/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/app/instructions.md @@ -2,7 +2,7 @@ changes: - id: engine-pin-moves-to-0-6-2 summary: | - The toolchain now requires `@prisma/cli-engine@0.6.2` (up from 0.6.1). A project that pins `@prisma/cli-engine` itself must move the pin to `0.6.2`. + The toolchain now requires `@prisma/cli-engine@0.6.2` (up from 0.6.1). A project that pins `@prisma/cli-engine` itself must move the pin to `0.6.2`. With this engine the CLI prints its own name in hints and messages where it used to print a literal `{bin}`. detection: glob: "**/package.json" contains: @@ -12,3 +12,5 @@ changes: ## `engine-pin-moves-to-0-6-2` For every `package.json` matched by `detection`, change the `@prisma/cli-engine` version from `0.6.1` to `0.6.2` and reinstall. Projects assembled by the `prisma` CLI resolve the engine automatically. + +Engine 0.6.2 replaces the placeholder `{bin}` with the name of the CLI that was run. A hint that used to print as `{bin} db migrate` now prints as `prisma db migrate`. The replacement applies to next actions, warnings, errors, and summary and list text, in human, `--json`, and `--format markdown` output. If a script or a test of yours matches the literal text `{bin}` in the CLI's output, change it to match the CLI name. diff --git a/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/extension/instructions.md b/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/extension/instructions.md index 55faf3ea3c14..c638ae411dd3 100644 --- a/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/extension/instructions.md +++ b/upgrade-instructions/pending/engine-pin-moves-to-0-6-2/extension/instructions.md @@ -2,7 +2,7 @@ changes: - id: engine-pin-moves-to-0-6-2 summary: | - The toolchain now peers `@prisma/cli-engine@0.6.2` (up from 0.6.1). An extension package that pins `@prisma/cli-engine` for its tests or tooling must move the pin to `0.6.2`. + The toolchain now peers `@prisma/cli-engine@0.6.2` (up from 0.6.1). An extension package that pins `@prisma/cli-engine` for its tests or tooling must move the pin to `0.6.2`. With this engine the CLI prints its own name in hints and messages where it used to print a literal `{bin}`. detection: glob: "**/package.json" contains: @@ -12,3 +12,5 @@ changes: ## `engine-pin-moves-to-0-6-2` For every `package.json` matched by `detection`, change the `@prisma/cli-engine` version from `0.6.1` to `0.6.2` and reinstall. + +Engine 0.6.2 replaces the placeholder `{bin}` with the name of the CLI that was run. A hint that used to print as `{bin} db migrate` now prints as `prisma db migrate`. The replacement applies to next actions, warnings, errors, and summary and list text, in human, `--json`, and `--format markdown` output. Keep writing `{bin}` in the commands and messages your extension produces; the engine replaces it. If a test of yours runs the CLI and matches the literal text `{bin}` in its output, change it to match the CLI name.