🌟 Help us spread the word about Prisma by starring the repo or tweeting about the release. 🌟
Highlights
In this sprint, we’ve made bug fixes and overall improvements to Prisma Client. We’ve been working on a few projects that will be announced soon. Stay tuned for the upcoming releases for updates!
Improvements and bug fixes
We made the following changes:
Prisma Client improvements
- Validation for
undefined
values in arrays inJson
fields
We added runtime validation forundefined
values in arrays inJson
fields. Prisma Client will now return an error when an array contains anundefined
value. Therefore, we encourage you to add validation that either removes the value or transforms it tonull
if you stumble on the runtime validation:// Query await prisma.user.findMany({ where: { // JSON field preferences: [undefined, '"theme": "dark"', null, ] } }) // Example error message on running the query Can not use `undefined` value within array. Use `null` or filter out `undefined` values
- Performance improvements for models with many unique fields: This release improves Prisma Client’s memory consumption for models with many
@unique
constraints. This was a regression from version 4.10.1, where in some cases, if a model had many unique constraints, Prisma Client would use up a lot of available memory. - Fixed the segmentation fault error that used to occur on ARM64 Linux binary targets
- Metrics Preview feature improvements:
- We updated the counters and gauge properties
- We fixed the bug that caused the
prisma_pool_connections_open
metric to have a negative value in some cases.
Prisma Migrate improvements
- Fixed an introspection bug for MongoDB views. Previously, if a MongoDB database contained a view,
prisma db pull
would throw an error. We resolved this, and views are now ignored. - Added the
PRISMA_SCHEMA_DISABLE_ADVISORY_LOCK
environment variable that enables you to disable advisory locking.
VS Code extension improvements
- Added support for rendering multi-line comments in tooltips when hovering on a block.
- Improved the auto-completion for composite types in other blocks.
- Added a Code Action that allows you to replace
SetDefault
withNoAction
when using MySQL and the default/foreignKeys
relation mode.
Fixes and improvements
Prisma Migrate
- Percona-XtraDB-Cluster prohibits use of GET_LOCK with pxc_strict_mode = ENFORCING
- MongoDB views should be ignored introspecting the database
- Error in Connector on MongoDB executing listIndex: "system.views"
prisma migrate deploy
:MariaDB doesn't yet support 'GET_LOCK in cluster (WSREP_ON=ON)'
Prisma Client
- Remove all special cases for Data Proxy in our tests
- Segmentation fault on ARM64 Linux
- In the metrics feature a gauge & counter are swapped
- The prisma metrics
prisma_pool_connections_open
has a bug where it goes negative - Prisma crashes with GraphQL queries of nested one-to-many relationship
- P1017 Server has closed the connection on linux_arm64
Error: socket hang up
on Linux/arm64- Panic in Query Engine with SIGABRT signal (Debian Bookworm, engineType = binary)
- Prisma 5 drops
undefined
from Arrays when using Json fields with Postgres - Suspected memory leak in Lambda function after upgrading from 4.10.1
- Error when generating - No unsupported field should reach that path
Language tools (e.g. VS Code)
- Models with multi line comments only show last line in tooltip
- Add VS Code quick fix / code action to replace
SetDefault
withNoAction
whenprovider = "mysql"
andrelationMode = "foreignKeys" | default
- Composite Types aren't offered as being auto-completable in other blocks
Credits
Huge thanks to @alencardc, @Oreilles, @christianledgard, @skyzh, @alula, @michaelpoellath, @RobertCraigie, @stephenwade for helping!