-
Notifications
You must be signed in to change notification settings - Fork 1.4k
fix(orm/typedsql): bump Prisma to 6.15.0 and refresh dev deps to resolve config type breakage #8293
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: latest
Are you sure you want to change the base?
Conversation
WalkthroughDependency updates in orm/typedsql/package.json: bumps @prisma/client, prisma, @types/node, and tsx versions, and adds dotenv as a new devDependency. No source files or runtime code changes are included. Changes
✨ Finishing Touches🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR/Issue comments)Type Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 4
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
orm/typedsql/package.json (1)
6-8
: Confirm thatpackage.json["prisma"].seed
remains your intended mechanism.It’s still supported, but many projects now prefer explicit
npm run db:seed
scripts for clarity. Optional, not blocking.Example (outside changed lines):
{ "scripts": { "db:seed": "dotenv -e .env -- tsx prisma/seed.ts" } }
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (1)
orm/typedsql/package.json
(1 hunks)
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-08-22T12:12:24.602Z
Learnt from: FGoessler
PR: prisma/prisma-examples#8260
File: generator-prisma-client/nextjs-starter-webpack-turborepo/packages/database/package.json:13-13
Timestamp: 2025-08-22T12:12:24.602Z
Learning: When analyzing changes from package.json seed scripts to "prisma db seed", always verify the actual content of prisma.config.ts rather than relying solely on regex patterns, as the configuration may be properly defined but in a format that doesn't match overly restrictive search patterns.
Applied to files:
orm/typedsql/package.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (24)
- GitHub Check: test (orm/ai-sdk-nextjs)
- GitHub Check: test (orm/astro)
- GitHub Check: test (orm/graphql-sdl-first)
- GitHub Check: test (orm/koa)
- GitHub Check: test (orm/express)
- GitHub Check: test (orm/fastify-graphql-sdl-first)
- GitHub Check: test (orm/clerk-nextjs)
- GitHub Check: test (orm/graphql)
- GitHub Check: test (orm/fastify)
- GitHub Check: test (orm/authjs-nextjs)
- GitHub Check: test (orm/betterauth-nextjs)
- GitHub Check: test (orm/hapi-graphql-sdl-first)
- GitHub Check: test (orm/nest-graphql-sdl-first)
- GitHub Check: test (orm/nest-graphql)
- GitHub Check: test (orm/nuxt)
- GitHub Check: test (orm/nest)
- GitHub Check: test (orm/fastify-graphql)
- GitHub Check: test (orm/graphql-nexus)
- GitHub Check: test (orm/grpc)
- GitHub Check: test (orm/hapi-graphql)
- GitHub Check: test (orm/nextjs-graphql)
- GitHub Check: test (orm/nextjs)
- GitHub Check: test (orm/solid-start)
- GitHub Check: test (orm/sveltekit)
🔇 Additional comments (1)
orm/typedsql/package.json (1)
25-25
: tsx patch bump is safe.No breaking changes expected; just ensure CI cache is invalidated so new binaries install cleanly.
@@ -16,11 +16,12 @@ | |||
"author": "", | |||
"license": "ISC", | |||
"dependencies": { | |||
"@prisma/client": "6.9.0" | |||
"@prisma/client": "6.15.0" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Verification agent
🧩 Analysis chain
Prisma Client bump to 6.15.0 looks good; ensure regeneration happens.
This aligns the example with current Prisma. Make sure @prisma/client
postinstall runs or that CI executes prisma generate
so TS types reflect 6.15.0.
Run:
🏁 Script executed:
#!/bin/bash
# Verify versions and that client is generated
jq -r '.dependencies["@prisma/client"]' orm/typedsql/package.json
jq -r '.devDependencies.prisma' orm/typedsql/package.json
rg -nP '(?i)prisma.*generate' -n -C2 orm/typedsql
Length of output: 1499
Ensure Prisma Client is regenerated after the version bump
Add a postinstall
script in orm/typedsql/package.json (or ensure your CI runs npx prisma generate
) so that TypeScript types are updated to 6.15.0, for example:
"scripts": {
"postinstall": "prisma generate"
}
🤖 Prompt for AI Agents
In orm/typedsql/package.json around line 19, after bumping "@prisma/client" to
6.15.0 the Prisma Client must be regenerated; add a postinstall script to
package.json that runs the Prisma generator (e.g., "postinstall": "prisma
generate") or ensure your CI installs runs npx prisma generate, then run the
generate step locally (or in CI) so TypeScript types are updated to the new
Prisma version.
"@types/node": "^24.3.0", | ||
"dotenv": "^17.2.2", | ||
"prisma": "6.15.0", | ||
"tsx": "4.20.5" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧹 Nitpick (assertive)
Dev deps bumps look fine; declare supported Node version to prevent type/runtime drift.
@types/node
^24 can expose newer APIs at type level; add an explicit engines constraint to document/support the intended Node runtime for this example.
Proposed addition (outside changed lines):
{
"engines": { "node": ">=18.18 <=26" }
}
Adjust the range to your CI/runtime.
🤖 Prompt for AI Agents
In orm/typedsql/package.json around lines 22 to 25, add an "engines" field to
declare the supported Node runtime to avoid type/runtime drift from bumping
@types/node; insert an "engines": { "node": ">=18.18 <=26" } (or adjust the
range to match your CI/runtime) at the top-level of package.json so package
managers and CI enforce the intended Node version.
"prisma": "6.9.0", | ||
"tsx": "4.20.3" | ||
"@types/node": "^24.3.0", | ||
"dotenv": "^17.2.2", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Verification agent
🧩 Analysis chain
dotenv is added but not wired; ensure .env loading is actually invoked.
Right now scripts won’t load .env
unless app code imports dotenv/config
. Either import it in src/index.ts
and prisma/seed.ts
, or wrap scripts with the dotenv CLI.
If you prefer script-based loading (recommended for examples), update scripts (outside changed lines) like:
{
"prisma": { "seed": "dotenv -e .env -- tsx prisma/seed.ts" },
"scripts": {
"start": "dotenv -e .env -- tsx src/index.ts",
"dev": "dotenv -e .env -- tsx src/index.ts --watch",
"test": "dotenv -e .env -- tsx src/index.ts",
"debug": "dotenv -e .env -- tsx src/index.ts"
}
}
Or add at the top of both entrypoints:
import 'dotenv/config'
Verification script:
🏁 Script executed:
#!/bin/bash
# Check if dotenv is imported or used via CLI
rg -nP 'dotenv/(config| -e )' -C2 orm/typedsql || true
Length of output: 55
🏁 Script executed:
#!/bin/bash
# Show the top of package.json to inspect scripts and dependencies
sed -n '1,200p' orm/typedsql/package.json
# Search for dotenv imports in TypeScript files
rg -nP "import\s+['\"]dotenv/config['\"]" -C2 orm/typedsql
# Search for dotenv requires in CommonJS-style files
rg -nP "require\(['\"]dotenv/config['\"]\)" -C2 orm/typedsql
# Broad search for any dotenv usage
rg -n 'dotenv' -C2 orm/typedsql
Length of output: 1039
Wire dotenv initialization
dotenv is installed but never invoked, so environment variables won’t load at runtime. You must either:
- Add at the top of both entrypoints (
src/index.ts
andprisma/seed.ts
):import 'dotenv/config'
- Or update your package.json scripts to wrap with the dotenv CLI, for example:
"prisma": { "seed": "dotenv -e .env -- tsx prisma/seed.ts" }, "scripts": { "start": "dotenv -e .env -- tsx src/index.ts", "dev": "dotenv -e .env -- tsx src/index.ts --watch", "test": "dotenv -e .env -- tsx src/index.ts", "debug": "dotenv -e .env -- tsx src/index.ts" }
🤖 Prompt for AI Agents
In orm/typedsql/package.json around line 23, dotenv is listed as a dependency
but never initialized, so environment variables won’t be loaded; fix by either
importing dotenv/config at the top of both entrypoints (src/index.ts and
prisma/seed.ts) or by updating package.json scripts to run the entrypoints via
the dotenv CLI (wrap the start/dev/test/debug and prisma.seed commands with
dotenv -e .env --) so the .env file is loaded before execution.
"tsx": "4.20.3" | ||
"@types/node": "^24.3.0", | ||
"dotenv": "^17.2.2", | ||
"prisma": "6.15.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Verification agent
🧩 Analysis chain
Prisma CLI 6.15.0 bump is consistent; validate config typing is resolved.
Since this PR targets a TypedSQL config type break, confirm prisma.config.ts
(if present) type-checks and that prisma db seed
still picks up your seed script.
Run:
If prisma.config.ts
exists, ensure it imports from @prisma/config
per 6.x typings.
🏁 Script executed:
#!/bin/bash
# Locate prisma.config and seed file
fd -a 'prisma.config.*' orm/typedsql || true
fd -a 'seed.ts' orm/typedsql || true
# Type-check if a tsconfig exists for the example
fd -a 'tsconfig*.json' orm/typedsql || true
Length of output: 152
Add Prisma TS config and tsconfig.json for TypeScript seed
No prisma.config.ts
or tsconfig.json
is present, so prisma db seed
won’t load the prisma/seed.ts
script. Create a prisma.config.ts
(importing from @prisma/config
per 6.x typings) alongside a tsconfig.json
to enable runtime compilation of your TypeScript seed.
🤖 Prompt for AI Agents
In orm/typedsql/package.json around line 24, the project pins Prisma 6.15.0 but
lacks the runtime TypeScript seed configuration; add a new prisma.config.ts file
in the prisma/ directory that imports the proper helper from @prisma/config and
exports the configuration so prisma db seed can load prisma/seed.ts, and also
add a project-level tsconfig.json (or prisma/tsconfig.json) enabling compilation
for runtime seeds (target ES2020/ESNext, module ESNext or CommonJS to match your
build, allowJs false, resolveJsonModule true, esModuleInterop true, skipLibCheck
true, and include "prisma" and "prisma/seed.ts") so Prisma will compile and run
the TypeScript seed script when running prisma db seed.
What’s in this PR
Updates the orm/typedsql example to the latest stable Prisma release to fix a TypeScript break caused by recent changes in Prisma’s config types.
Changes
@prisma/client
: 6.9.0 ➜ 6.15.0prisma
: 6.9.0 ➜ 6.15.0@types/node
: 22.15.32 ➜ ^24.3.0tsx
: 4.20.3 ➜ 4.20.5dotenv
to dev dependencies to make local env loading explicitWhy
Recent Prisma releases introduced updates around configuration typing, which caused the typedsql example to fail type-checking when following latest Prisma docs. Moving to 6.15.0 aligns the example with the current stable.
TypedSQL docs for reference: https://www.prisma.io/docs/orm/reference/prisma-config-reference
Notes
Summary by CodeRabbit