Skip to content
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

Update prisma monorepo to v5.20.0 #85

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Jun 4, 2024

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
@prisma/client (source) 5.19.1 -> 5.20.0 age adoption passing confidence
prisma (source) 5.19.1 -> 5.20.0 age adoption passing confidence

Release Notes

prisma/prisma (@​prisma/client)

v5.20.0

Compare Source

🌟 Help us spread the word about Prisma by starring the repo or posting on X about the release. 🌟

Highlights

strictUndefinedChecks in Preview

With Prisma ORM 5.20.0, the Preview feature strictUndefinedChecks will disallow any value that is explicitly undefined and will be a runtime error. This change is direct feedback from this GitHub issue and follows our latest proposal on the same issue.

To demonstrate the change, take the following code snippet:

prisma.table.deleteMany({
  where: {
    // If `nullableThing` is nullish, this query will remove all data.
    email: nullableThing?.property,
  }
})

In Prisma ORM 5.19.0 and below, this could result in unintended behavior. In Prisma ORM 5.20.0, if the strictUndefinedChecks Preview feature is enabled, you will get a runtime error instead:

Invalid \`prisma.user.findMany()\` invocation in
/client/tests/functional/strictUndefinedChecks/test.ts:0:0
  XX })
  XX 
  XX test('throws on undefined input field', async () => {
→ XX   const result = prisma.user.deleteMany({
         where: {
           email: undefined
                  ~~~~~~~~~
         }
       })
Invalid value for argument \`where\`: explicitly \`undefined\` values are not allowed."

We have also introduced the Prisma.skip symbol, which will allow you to get the previous behavior if desired.

prisma.table.findMany({
  where: {
    // Use Prisma.skip to skip parts of the query
    email: nullableEmail ?? Prisma.skip
  }
})

From Prisma ORM 5.20.0 onward, we recommend enabling strictUndefinedChecks, along with the TypeScript compiler option exactOptionalPropertyTypes, which will help catch cases of undefined values at compile time. Together, these two changes will help protect your Prisma queries from potentially destructive behavior.

strictUndefinedChecks will be a valid Preview feature for the remainder of Prisma ORM 5. With our next major version, this behavior will become the default and the Preview feature will be “graduated” to Generally Available.

If you have any questions or feedback about strictUndefinedChecks, please ask/comment in our dedicated Preview feature GitHub discussion.

typedSql bug fix

Thank you to everyone who has tried out our typedSql Preview feature and provided feedback! This release has a quick fix for typescript files generated when Prisma Schema enums had hyphens.

Fixes and improvements

Prisma
Prisma Engines

Credits

Huge thanks to @​mcuelenaere, @​pagewang0, @​key-moon, @​pranayat, @​yubrot, @​thijmenjk, @​mydea, @​HRM, @​haaawk, @​baileywickham, @​brian-dlee, @​nickcarnival, @​eruditmorina, @​nzakas, and @​gutyerrez for helping!


Configuration

📅 Schedule: Branch creation - "before 2am" in timezone Asia/Manila, Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about these updates again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot changed the title Update prisma monorepo to v5.15.0 Update prisma monorepo to v5.15.1 Jun 18, 2024
@renovate renovate bot changed the title Update prisma monorepo to v5.15.1 Update prisma monorepo to v5.16.0 Jun 25, 2024
@renovate renovate bot changed the title Update prisma monorepo to v5.16.0 Update prisma monorepo to v5.16.1 Jun 27, 2024
@renovate renovate bot force-pushed the renovate/prisma-monorepo branch 2 times, most recently from cef733c to 6992268 Compare June 30, 2024 08:36
@renovate renovate bot changed the title Update prisma monorepo to v5.16.1 Update prisma monorepo to v5.16.2 Jul 9, 2024
@renovate renovate bot changed the title Update prisma monorepo to v5.16.2 Update prisma monorepo to v5.17.0 Jul 16, 2024
@renovate renovate bot force-pushed the renovate/prisma-monorepo branch from 6992268 to 2ba17b8 Compare August 4, 2024 04:43
@renovate renovate bot changed the title Update prisma monorepo to v5.17.0 Update prisma monorepo to v5.18.0 Aug 6, 2024
@renovate renovate bot force-pushed the renovate/prisma-monorepo branch from 2ba17b8 to 1cb53a6 Compare August 21, 2024 16:18
@renovate renovate bot changed the title Update prisma monorepo to v5.18.0 Update prisma monorepo to v5.19.0 Aug 27, 2024
@renovate renovate bot changed the title Update prisma monorepo to v5.19.0 Update prisma monorepo to v5.19.1 Sep 2, 2024
@renovate renovate bot force-pushed the renovate/prisma-monorepo branch 2 times, most recently from bc2898c to 903246b Compare September 16, 2024 19:23
@renovate renovate bot changed the title Update prisma monorepo to v5.19.1 Update prisma monorepo to v5.19.1 - autoclosed Sep 17, 2024
@renovate renovate bot closed this Sep 17, 2024
@renovate renovate bot deleted the renovate/prisma-monorepo branch September 17, 2024 18:20
@renovate renovate bot changed the title Update prisma monorepo to v5.19.1 - autoclosed Update prisma monorepo to v5.19.1 Sep 24, 2024
@renovate renovate bot reopened this Sep 24, 2024
@renovate renovate bot restored the renovate/prisma-monorepo branch September 24, 2024 16:42
@renovate renovate bot changed the title Update prisma monorepo to v5.19.1 Update prisma monorepo to v5.20.0 Sep 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants