This repository was archived by the owner on Mar 7, 2023. It is now read-only.
chore(deps): update dependency @prisma/get-platform to v4 - #55
Open
renovate[bot] wants to merge 1 commit into
Open
chore(deps): update dependency @prisma/get-platform to v4#55renovate[bot] wants to merge 1 commit into
renovate[bot] wants to merge 1 commit into
Conversation
renovate
Bot
force-pushed
the
renovate/major-prisma-monorepo
branch
from
July 28, 2022 13:31
37ccbaf to
036c2ca
Compare
renovate
Bot
force-pushed
the
renovate/major-prisma-monorepo
branch
2 times, most recently
from
August 10, 2022 16:37
3f6b097 to
a81a96e
Compare
renovate
Bot
force-pushed
the
renovate/major-prisma-monorepo
branch
2 times, most recently
from
September 1, 2022 19:10
0a3a13e to
32898ad
Compare
renovate
Bot
force-pushed
the
renovate/major-prisma-monorepo
branch
from
September 27, 2022 21:54
32898ad to
2e4001c
Compare
renovate
Bot
force-pushed
the
renovate/major-prisma-monorepo
branch
from
October 18, 2022 16:30
2e4001c to
6436edc
Compare
renovate
Bot
force-pushed
the
renovate/major-prisma-monorepo
branch
2 times, most recently
from
November 13, 2022 16:11
d6f0093 to
ee8aa4d
Compare
renovate
Bot
force-pushed
the
renovate/major-prisma-monorepo
branch
2 times, most recently
from
December 5, 2022 10:54
3ef3936 to
73cfc3b
Compare
renovate
Bot
force-pushed
the
renovate/major-prisma-monorepo
branch
from
December 23, 2022 19:16
73cfc3b to
4a49de0
Compare
renovate
Bot
force-pushed
the
renovate/major-prisma-monorepo
branch
from
January 8, 2023 18:38
4a49de0 to
cefac28
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
2.30.0-28.60b19f4a1de4fe95741da371b4c44a92f4d1adcb->4.8.1Release Notes
prisma/prisma
v4.8.1Compare Source
Today, we are issuing the
4.8.1patch release.Fix in Prisma Client
v4.8.0Compare Source
🌟 Help us spread the word about Prisma by starring the repo or tweeting about the release. 🌟
Highlights
Improved serverless experience — smaller engines size
In this release, we have decreased the size of our engine files by an average of 50%. The size of the Query Engine used on Debian, with OpenSSL 3.0.x, for example, went from 39MB to 14MB. We will also remove some smaller engines to decrease the total size in future versions.
Additionally, we have started optimizing how the Prisma schema is loaded in Prisma Client. You should notice a considerable improvement when executing the first query if you're working with a bigger schema with many models and relations.
We will continue investing in this direction in the next releases and further improve the experience with Prisma and serverless environments.
Multi-schema support for CockroachDB (Preview)
We're pleased to share that this release adds Preview support for multi-schema for CockroachDB. 🎉
This release adds support for:
If you already have a CockroachDB database using multiple schemas, you can quickly get up and running set up multiple schemas by:
schemasproperty in thedatasourceblockprisma db pullYou can further evolve your database schema using the multi-schema Preview feature by using
prisma migrate dev.For further details, refer to our documentation and let us know what you think in this GitHub issue.
Improved OpenSSL 3.x support
Prisma now supports OpenSSL 3 builds for Linux Alpine on
x86_64architectures. This particularly impacts users running Prisma onnode:alpineandnode:lts-alpineDocker images. The images are based on an Alpine version that ships with OpenSSL 3.0.x, which isn’t compatible with OpenSSL 1.1.x (already supported by Prisma). You can read more details about it in this GitHub comment.We also have rewritten our OpenSSL version detection logic, making it future-proof. We now expect Prisma to support systems running with any OpenSSL 3 minor versions out of the box.
Fixes and improvements
Prisma
Uuidhas no default operator class.migrate resetonly resets first schemamultiSchemaintrospectionmigrate devdoes not detect drift between database schema and migration history formultiSchemaPrisma Migrate
multiSchemapreview feature with MySQLPrisma Client
clientExtensionspreview feature is used$extendsTS error: "Inferred type of this node exceeds the maximum length the compiler will serialize" with"declaration": trueintsconfigargsisundefinedconsole.logoutputs incorrect value whenresultextensions are usedextendedWhereUniqueon SQLLanguage tools (e.g. VS Code)
@mapalthough already present'in optional arguments contextPrisma Engines
@@​schemaattribute should always be required whenschemasis defined in the datasourceCredits
Huge thanks to @ivan, @Mini256, @cmd-johnson for helping!
Prisma Help Center (New)
We recently just launched our Help Center that you can use to find resources and get help from our support team for both the Prisma ORM and the Prisma Data Platform.
Check it out, and let us know what you think.
📺 Join us for another "What's new in Prisma" live stream
Learn about the latest release and other news from the Prisma community by joining us for another "What's new in Prisma" live stream.
The stream takes place on YouTube on Thursday, December 22 at 5 pm Berlin | 8 am San Francisco.
v4.7.1Compare Source
Today, we are issuing the
4.7.1patch release.Fixes in Prisma Client
clientExtensionspreview feature is usedconsole.logoutputs incorrect value whenresultextensions are usedfindUniqueOrThrowargsisundefinedv4.7.0Compare Source
🌟 Help us spread the word about Prisma by starring the repo or tweeting about the release. 🌟
Highlights
Interactive transactions are now Generally Available
After an extensive Preview phase and lots of great feedback from our community, we're excited to announce that
interactiveTransactionsis now Generally Available and production ready! 🚀Interactive transactions allow you to pass an async function into a
$transaction, and execute any code you like between the individual Prisma Client queries. Once the application reaches the end of the function, the transaction is committed to the database. If your application encounters an error as the transaction is being executed, the function will throw an exception and automatically rollback the transaction.Here are some of the feature highlights we've built:
4.2.04.6.0Here's an example of an interactive transaction with a
Serializableisolation level:You can now remove the
interactiveTransactionsPreview feature in your schema.Relation mode is Generally Available
This release marks
relationMode="prisma"as stable for our users working with databases that don't rely on foreign keys to manage relations. 🎉Prisma’s relation mode started as a way to support PlanetScale which does not allow you to create foreign keys for better online migration support. We transformed that into our Referential Integrity Emulation in
3.1.1when we realised that more users could benefit from it, and then integrated it as the default mode for MongoDB, which generally does not have foreign keys. Prisma needed to use emulation to give the same guarantees.We then realized the feature was more than just referential integrity and affected how relations work. To reflect this, we renamed the feature to relation mode and the
datasourceproperty torelationModein4.5.0Index warnings for
relationMode = "prisma"In this release, we've added a warning to our Prisma schema validation that informs you that the lack of foreign keys might result in slower performance — and that you should add an
@@​indexmanually to your schema to counter that. This ensures your queries are equally fast in relation modeprismaas they are with foreign keys.We also added a fix to our VS Code extension to help adding the suggested index with minimal effort:
If you are currently using the Preview feature flag to enable relation mode, you can now remove
referentialIntegrityfrom thepreviewFeaturesin yourgenerator clientblock in your Prisma schema.For more information, check out our updated relation mode documentation.
Prisma Client Extensions (Preview)
This release adds Preview support for Prisma Client Extensions. This feature introduces new capabilities to customize and extend Prisma Client. Today we are opening up four areas for extending Prisma Client:
model: add custom methods or fields to your modelsclient: add client-level methods to Prisma Clientresult: add custom fields to your query resultsquery: create custom Prisma Client queriesPrisma Client Extensions are self-contained scripts that can tweak the behavior of models, queries, results, and the client (Prisma Client) as a whole. You can associate a single or multiple extensions with an extended client to mix and match Prisma to your needs.
Prisma Client Extensions enables many use cases such as defining virtual fields, custom validation, and custom queries.
It also enables you to share your client extensions with others and import client extensions developed by others into your project.
For example, given the following schema:
You can create a computed field called
fullNameas follows:We're excited to see what you build with them! For more information, check out our docs and let us know what you think in this GitHub issue.
Multi-schema support for PostgreSQL (Preview)
We're pleased to announce that this release adds support for multi-schema support for PostgreSQL. The ability to query and manage multiple database schemas has been a long-standing feature request from our community.
This release adds support for the following:
If you already have a PostgreSQL database using multiple schemas, you can quickly get up and running using
prisma db pull— on enabling the Preview feature and specifying the schemas in thedatasourceblock similar to the example below.You can get started with defining multiple schemas in your Prisma schema as follows:
Then generate and apply the changes to your database with
prisma migrate dev.We want to thank all our users for helping us design the feature since the early proposal on GitHub up to our current Preview release.
For further details, refer to our documentation and let us know what you think in this GitHub issue.
Request for feedback
Our Product team is currently running a survey for designing Database Views support for Prisma and we would appreciate your feedback.
Fixes and improvements
Prisma Client
RangeError: Invalid count valueduringnpx prisma generatewithDEBUG=*on integration buildreferentialIntegritybinaryengineerroreventPrisma.TransactionClienttodefault-index.d.tsfindManyerrors withPANIC: index out of bounds: the len is 0 but the index is 0upsert()with nested selection errors withcalledOption::unwrap()on aNonevaluein 4.6.0findUniqueconcurrently with different key order causes one of them to return nullfindUniqueOrThrowvia middlewareprisma/ Reproduction test for prisma#16390Prisma
referentialIntegrity(renamed torelationMode)db pullwithmultiSchemaerror on schema with 2 models with the same table name but in a different schemarelationMode: make feature GASetDefaultvalidation error with warnings whenprovider = "mysql"andrelationMode = "foreignKeys" | defaultrelationModevalidation warning messagesprisma validate&prisma formatPrisma Migrate
prisma migrate devLanguage tools (e.g. VS Code)
@@​ignored and fields that are@ignoredreferentialIntegrity = "prisma"extensionswhenpostgresqlExtensionspreview feature is setrelationModeGA - remove preview feature conditionrelationMode="prisma", for@relation: add a warning if there is no index on the field(s)relationMode: missing foreign keys' indexesPrisma Engines
Credits
Huge thanks to @cmd-johnson, @jsoref, @miguelgargallo for helping!
Prisma Data Platform
We're working on the Prisma Data Platform — a collaborative environment for connecting apps to databases. It includes the following:
Try it out. Let us know what you think!
📺 Join us for another "What's new in Prisma" live stream
Learn about the latest release and other news from the Prisma community by joining us for another "What's new in Prisma" live stream.
The stream takes place on YouTube on Thursday, December 1 at 5 pm Berlin | 8 am San Francisco.
v4.6.1Compare Source
Today, we are issuing the
4.6.1patch release.Fixes in Prisma Client
findManyerrors withPANIC: index out of bounds: the len is 0 but the index is 0upsert()with nested selection errors withcalledOption::unwrap()on aNonevaluein 4.6.0Fix in Prisma Migrate
v4.6.0Compare Source
🌟 Help us spread the word about Prisma by starring the repo or tweeting about the release. 🌟
Highlights
Interactive Transactions for Prisma Data Proxy (Preview)
In 3.8.0, we disabled the
interactiveTransactionsPreview feature when using the Prisma Data Proxy. This was because the API was not yet supported.In this release, we're removing the limitation. You can now try the Preview version of interactive transactions with the Prisma Data Proxy. Re-generate Prisma Client using
prisma generate --data-proxyafter enabling the Preview feature.Note: The
interactiveTransactionsPreview feature flag is still needed. We will remove this in a future version when the feature is stable.Try it out and let us know your thoughts in our interactive transactions feedback GitHub issue.
Native database level upserts for PostgreSQL, SQLite, and CockroachDB
Prisma’s upsert is one of its most powerful and most convenient APIs. In this release, Prisma will now default to the native database upsert for PostgreSQL, SQLite, and CockroachDB whenever possible.
Prisma will use the native database upsert if:
upsert'screateandupdateoptionsupsert'swhereoptionwhereoption and the unique field in thecreateoption have the same valuePrisma Client's
upsertoperation was implemented on a Prisma-level and did not use the native database implementations like, e.g.,INSERT .. ON CONFLICT .. UPDATE SET. This allowed Prisma to also upsert nested queries.The Prisma-implementation came at a cost. In some scenarios, it was more likely for a transaction to roll back because of a conflict when multiple
upsertoperations were being executed in parallel, and the multiple queries often took longer than the native database query would have taken.Try it out and let us know what you think. If you run into any issues, don't hesitate to create a GitHub issue.
Relation Mode improvements (Preview)
In 4.5.0, we renamed the "Referential Integrity" Preview feature to "Relation Mode". We also changed the
datasourceproperty name of the feature torelationMode.In this release, we fixed all remaining known bugs of
relationMode = "prisma"and cleaned up our documentation. You can now read about Relation mode on its own documentation page which is up to date with the implementation.If you encounter any problems please comment on our feedback issue. We plan to make this Generally Available soon.
extendedWhereUniqueimprovements (Preview)In 4.5.0, we introduced the
extendedWhereUniquePreview feature to allow filtering for non-unique properties in unique where queries. In this release, we're adding new rules to decide when concurrentfindUniquequeries get batched into afindManyquery.Unfortunately, we forgot to adapt our
findUniquequery batch optimization, which turns multiple concurrentfindUniquequeries into a singlefindManyquery when possible — GitHub issue.Therefore,
findUniquequeries will get batched into afindManyquery if:where: { field: <val>, field1: { equals: <val> } })Conversely, suppose the filter object contains any boolean operators, relation filters, or scalar filters that are not using
equals. Prisma will fall back to executing thefindUniquequeries independently.Let us know your thoughts and share your feedback on the Preview feature in this GitHub issue.
Fixes and improvements
Prisma Client
relationMode=prismaupsert()should do ON CONFLICT DO UPDATE/NOTHING in postgresqlbinaryEnginereferentialIntegrity = "prisma"): MakeNoActiona synonym/alias ofRestrictfor the emulation, for all databases except PostgreSQL & SQLite.OnDelete: SetNullwithreferentialIntegrity = "prisma"user.delete()should fail, but succeeds.Prisma
referentialIntegrity = prismanot respected when using@@​map()SetNullreferential action referencing non-optional fieldsreferentialIntegritypolicy is lost during re-introspectionLanguage tools (e.g. VS Code)
Design Partner Program
Are you building data-intensive applications in serverless environments using Prisma? If so, you should join our Design Partner Program to help us build the tools that best fit your workflows!
The Design Partner Program aims to help development teams solve operational, data-related challenges in serverless environments. Specifically, we’re looking to build tools that help with the following problems:
Submit an application through our application form to join the Prisma Design Partner Program to take advantage of new features that you won't have to build or maintain yourselves.
Prisma Data Platform
We're working on the Prisma Data Platform — a collaborative environment for connecting apps to databases. It includes the following:
Try it out. Let us know what you think!
📺 Join us for another "What's new in Prisma" live stream
Learn about the latest release and other news from the Prisma community by joining us for another "What's new in Prisma" live stream.
The stream takes place on YouTube on Thursday, November 10 at 5 pm Berlin | 8 am San Francisco.
Credits
Huge thanks to @cmd-johnson for helping!
v4.5.0Compare Source
🌟 Help us spread the word about Prisma by starring the repo or tweeting about the release. 🌟
Major improvements
Filter for non-unique properties in unique where queries (Preview)
In this release, we are adding support for non-unique properties inside the
wherestatement for queries that operate on a unique record (e.g.:findUnique,update,delete, etc.). This was not possible in the past, as we only allowed unique fields as filters inside thewherestatement for the queries in question.There are use cases where a query that operates on a unique record requires further filtering by non-unique properties. For example, for the following model:
Let’s say that you would like to update the
Articlewith anidof “5”, but only if theversionequals "1":With
4.5.0, we are adding support to specify any number of non-unique fields in yourwherestatement, as long as you have at least one unique field.To use it, enable the Preview feature flag:
To learn more about this feature and about use cases where it can be useful, please check out our documentation. For feedback, please leave a comment on the GitHub issue.
PostgreSQL extension management (Preview)
We are excited to add support for declaring PostgreSQL extensions in the Prisma schema. The feature comes with support for introspection and migrations. This will allow you to adopt, evolve and manage which PostgreSQL database extensions are installed directly from within your Prisma schema.
To try this feature, enable the Preview feature flag:
Now you will be able to use the new
extensionsproperty in thedatasourceblock of your Prisma schema.Please visit our documentation to learn more about this feature or leave a comment with feedback on the GitHub issue.
Change to Referential Integrity — property in
datasourceblock renamed torelationMode(Preview)To prepare Prisma Client’s emulation of relations for general availability, we are releasing several improvements to the
referentialIntegrityPreview feature.We decided to rename the feature to Relation Mode. We think this closer reflects what this feature does and distinguishes it from integrity management on the database level. The related property in the
datasourceblock of the Prisma schema has also been changed fromreferentialIntegritytorelationMode.To use it, keep using the old
referentialIntegrityPreview feature flag:But use the new property name in the
datasource:We also removed the referential action
NoActionfor PostgreSQL and SQLite when usingrelationMode = "prisma"as we are not planning to support the details of the database behavior.To learn more about
relationMode, please check out the documentation or leave a comment on the GitHub issue.Deno for Prisma Client for Data Proxy (Preview)
Deno is an alternative JavaScript runtime that can replace Node.js to run JS and TS apps. It aligns itself closely with web technologies, claims to be secure by default, and supports TypeScript out of the box.
Today we are releasing initial support for Prisma with Deno via an integration for our Prisma Client for Data Proxy. This feature was developed together with the amazing team at Deno 🦕.
To use Prisma Client in a Deno project, add the
denoPreview feature flag to your Prisma schema and define a folder asoutput(this is required for Deno):Now you can generate Prisma Client with the Data Proxy using the command
npx prisma generate --data-proxy. Then use Prisma Client in your Deno script with the following import:You can also deploy an app built and configured like this on Deno Deploy, Deno’s deployment platform. Read this guide in our documentation for a full example and individual steps.
For feedback, please comment on this GitHub issue.
Fixed “Invalid string length” error in Prisma Studio and Prisma Data Platform Data Browser
Many people were having issues with an "Invalid string length" error both in Prisma Studio and Prisma Data Platform Data Browser. This issue can be resolved through this workaround. With this release, the root cause of this issue has been fixed and it should not occur again.
Updated proposal for Client Extensions: request for comments
In
4.3.0, we shared a proposal for Prisma Client Extensions on Github. We received a lot of great feedback, which we have incorporated into a new proposal.If you’re interested, please head over to the new proposal in GitHub and tell us what you think. Thank you!
Fixes and improvements
Prisma
onDelete: setDefaultreferentialIntegritymodes makes migration history obsoletereferentialIntegrityandrelationModePrisma Client
Prisma Migrate
postgresqlExtensions:migrate deverrors withERROR: type "citext" does not existwhen settingextensions = [citext]Language tools (e.g. VS Code)
relationMode(previouslyreferentialIntegrity) in the datasource blockCredits
Huge thanks to @kt3k, @abenhamdine, @jsoref for helping!
v4.4.0Compare Source
🌟 Help us spread the word about Prisma by starring the repo or tweeting about the release. 🌟
Major improvements
General improvements
In the last sprint, we focused our efforts on squashing as many bugs as we could. You can find the full list of improvements and bug fixes in the Fixes and improvements section below.
Some of the improvements we made include but are not limited to:
Databases impose limits when they hit a specific number, and when a query (either generated by Prisma Client or provided by the user directly as a raw query) hits it some users ran into a misleading
Can't reach database servererror message (GitHub issue). The error message will now be more useful (P2035error code), and Prisma Client should not cause these errors anymore.If you notice any regression, please make sure to create a GitHub issue. We touched a lot of code in this sprint, and even though we are confident in our tests, something might have slipped through the cracks. We'd like to fix the regressions as soon as possible.
isolationLevelfor sequential transaction operationsIn version
4.2.0, we added support for setting transaction isolation levels for interactive transactions (Preview). You can now define isolation levels for sequential transaction operations:prisma.$transaction([]).Isolation levels describe different types of trade-offs between isolation and performance that databases can make when processing transactions. Isolation levels determine what types of data leaking can occur between transactions or what data anomalies can occur.
To set the transaction isolation level, use the
isolationLeveloption in the second parameter of the API. For example:Prisma Client supports the following isolation levels if they're available in your database provider:
ReadCommittedReadUncommittedRepeatableReadSerializableSnapshotLearn more about it in our documentation.
New
P2034error code for transaction conflicts or deadlocksWhen using certain isolation levels, it is expected that a transaction can fail due to a write conflict or a deadlock, throwing an error. One way to solve these cases is by retrying the transaction.
To make this easier, we're introducing a new
PrismaClientKnownRequestErrorwith the error codeP2034: "Transaction failed due to a write conflict or a deadlock. Please retry your transaction". You can programmatically catch the error and retry the transaction. Here's an example showing how you can retry a transaction:Fixes and improvements
Prisma Client
rejectOnNotFoundupdateMany()causes lost-updatesList<String | DateTime>into field of typeList<String>$transaction([deleteMany, createMany])numericrangeThe provided database string is invalid. Unable to parse URL. in database URL.on invalid (?) connection stringcreatedAt @​default(now())andupdatedAt @​updatedAtget different times on row creation$fooError: The provided database string is invalid. Unable to parse URL. in database URL.findRawdoes not work within aninteractiveTransactionConfiguration
📅 Schedule: Branch creation - "every weekend" in timezone Asia/Shanghai, Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.