Skip to content
This repository has been archived by the owner on May 15, 2022. It is now read-only.

chore(deps): update all non-major dependencies #108

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

Conversation

renovate[bot]
Copy link

@renovate renovate bot commented Mar 27, 2022

WhiteSource Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
@discordjs/rest (source) ^0.3.0 -> ^0.4.1 age adoption passing confidence
@prisma/client (source) ^3.11.0 -> ^3.14.0 age adoption passing confidence
@sapphire/decorators ^4.3.3 -> ^4.3.4 age adoption passing confidence
@sapphire/type ^2.2.0 -> ^2.2.4 age adoption passing confidence
@types/cookie-parser ^1.4.2 -> ^1.4.3 age adoption passing confidence
@types/node ^16.11.26 -> ^16.11.35 age adoption passing confidence
@typescript-eslint/eslint-plugin ^5.16.0 -> ^5.23.0 age adoption passing confidence
@typescript-eslint/parser ^5.16.0 -> ^5.23.0 age adoption passing confidence
axios (source) ^0.26.1 -> ^0.27.2 age adoption passing confidence
body-parser ^1.19.2 -> ^1.20.0 age adoption passing confidence
discord.js (source) ^13.6.0 -> ^13.7.0 age adoption passing confidence
dotenv ^16.0.0 -> ^16.0.1 age adoption passing confidence
eslint (source) ^8.11.0 -> ^8.15.0 age adoption passing confidence
express (source) ^4.17.3 -> ^4.18.1 age adoption passing confidence
genius-lyrics (source) ^4.3.6 -> ^4.3.8 age adoption passing confidence
moment (source) ^2.29.1 -> ^2.29.3 age adoption passing confidence
prisma (source) ^3.11.0 -> ^3.14.0 age adoption passing confidence
typescript (source) ^4.6.2 -> ^4.6.4 age adoption passing confidence

Release Notes

discordjs/discord.js

v0.4.1

Compare Source

v0.4.0

Compare Source

Bug Fixes

Documentation

Features

Refactor

Testing

prisma/prisma

v3.14.0

Compare Source

🌟 Help us spread the word about Prisma by starring the repo or tweeting about the release. 🌟

Major improvements

CockroachDB connector is now Generally Available!

We are proud to announce the CockroachDB connector is now stable and Generally Available. The connector was built in joined efforts with the team at Cockroach Labs and comes with full Prisma Client and Prisma Migrate support.

If you're upgrading from Prisma version 3.9.0+ or the PostgreSQL connector, you can now run npx prisma db pull and review the changes to your schema. To learn more about CockroachDB-specific native types we support, refer to our docs.

To learn more about the connector and how it differs from PostgreSQL, head to our documentation.

PostgreSQL GIN, GiST, SP-GiST, and BRIN indexes support (Preview)

We introduced the extendedIndexes Preview feature in version 3.5.0, and we have been adding new configuration options for indexes. We've expanded index type support with the GIN, GiST, SP-GiST, and BRIN indexes in this release.

To make use of an index type, you can update your Prisma schema by providing the type argument to the @@​index attribute:

datasource db {
  provider = "postgresql"
  url      = env("DATABASE_URL")
}

generator client {
  provider        = "prisma-client-js"
  previewFeatures = ["extendedIndexes"]
}

model Post {
  id      Int     @​id
  title   String
  content String?
  tags    Json?

  @​@​index([tags], type: Gin)
}

The following SQL will be generated in your migration when you run prisma migrate dev:

CREATE TABLE "Post" (
    "id" INTEGER NOT NULL,
    "title" TEXT NOT NULL,
    "content" TEXT,
    "tags" JSONB,
    CONSTRAINT "Post_pkey" PRIMARY KEY ("id")
);

CREATE INDEX "Post_tags_idx" ON "Post" USING GIN ("tags");

To learn more about configuring index types in your schema, refer to our documentation.

Improved queryRaw API

In this release, we made improvements to the SQL raw API. Some improvements are breaking and will be available behind the new improvedQueryRaw Preview feature flag.

The improvedQueryRaw Preview feature solves most of the issues faced when working with the raw API. We would encourage you to turn on the Preview feature flag, try out the new API, and let us know how we can make it even better.

You can enable the Preview feature in your Prisma schema as follows:

datasource db {
  provider = "postgresql"
  url      = env("DATABASE_URL")
}

generator client {
  provider        = "prisma-client-js"
  previewFeatures = ["improvedQueryRaw"]
}

Here's a list of the improvements improvedQueryRaw comes with:

1. Raw scalar values are deserialized as their correct JavaScript types

Prisma Client queries such as findMany deserialize database scalar values to their corresponding JavaScript types. For example, a DateTime value is deserialized as a JavaScript Date, and a Bytes would be deserialized as a JavaScript Buffer.

Raw queries now implement the same behavior when the improvedQueryRaw Preview feature flag is enabled.

⚠️ This change is not yet available in the SQLite connector.

The types of values from the database will be used instead of the types in the Prisma schema. Here's an example query and response:

const res = await prisma.$queryRaw`SELECT bigint, bytes, decimal, date FROM "Table";`
console.log(res) 
// [{ bigint: BigInt("123"), bytes: Buffer.from([1, 2]), decimal: new Prisma.Decimal("12.34"), date: Date("<some_date>") }]

Here's a table that recaps the serialization type-mapping for raw results:

Database Type Javascript Type
Text String
Int32 Number
Float Number
Double Number
Int64 BigInt
Numeric Decimal
Bytes Buffer
Json Object
DateTime Date
Date Date
Time Date
Uuid String
Xml String
2. PostgreSQL type-casts

We've also fixed a lot of PostgreSQL type-casts that were broken by enabling the improvedQueryRaw Preview feature flag.

Here's an example of a query that used to fail:

await prisma.$queryRaw`SELECT ${1.5}::int as int`;
// Before: db error: ERROR: incorrect binary data format in bind parameter 1
// After: [{ int: 2 }]

You can now perform some more type-casts in your queries:

await prisma.$queryRaw`SELECT ${2020}::float4, (NOW() - ${"1 day"}::interval), ${"2022-01-01 00:00:00"}::timestamptz;`

A consequence of this fix is that some subtle implicit casts are now handled more strictly and would fail. Here's an example that used to work but won't work anymore under the improvedQueryRaw feature flag:

await prisma.$queryRaw`SELECT LENGTH(${42});`
// ERROR: function length(integer) does not exist
// HINT: No function matches the given name and argument types. You might need to add explicit type casts.

The LENGTH PostgreSQL function only accept text as input. Prisma used to coerce 42 to text silently, but won’t anymore. As suggested by the hint, cast 42 to text as follows:

await prisma.$queryRaw`SELECT LENGTH(${42}::text);`
3. Query parameters are correctly sent to the database

This improvement is available without the improvedQueryRaw Preview feature flag.

Before this release, query parameters of type BigInt, Bytes, and Decimal were incorrectly sent to the database leading to instances of unexpected inserts. Passing the types as query parameters now works:

await prisma.$executeRaw`INSERT INTO "Table" ("bigint", "bytes", "decimal") VALUES (${BigInt("123")}, ${Buffer.from([1, 2, 3])}, ${new Prisma.Decimal("12.23")});`

Fixes and improvements

Prisma Client
Prisma
Prisma Migrate
Language tools (e.g. VS Code)

Credits

Huge thanks to @​ever0de, @​flatplate, @​njmaeff, @​tnzk, @​DePasqualeOrg for helping!

Prisma Day

Prisma Day is back this year, and it'll be on June 15 - 16 at the JamesJune Sommergarten in Berlin. Join us in-person or online for talks and workshops on modern application development and databases. Come and meet and chat with the team behind the Prisma ORM and Prisma Data Platform.

💼 We're hiring!

If you're interested in joining our growing team to help empower developers to build data-intensive applications, Prisma is the place for you.

We're hiring for a number of roles: Technical Support Engineer, Back-end Engineer: Prisma Data Platform, and a Developer Advocate(Frontend/ Fullstack). You can find more jobs we're hiring for on our jobs page.

Feel free to read through the job descriptions and apply using the links provided.

📺 Join us for another "What's new in Prisma" livestream

Learn about the latest release and other news from the Prisma community by joining us for another "What's new in Prisma" livestream.

The stream takes place on YouTube on Thursday, May 12 at 5 pm Berlin | 8 am San Francisco.

v3.13.0

Compare Source

Today, we are excited to share the 3.13.0 stable release 🎉

🌟 Help us spread the word about Prisma by starring the repo or tweeting about the release. 🌟

Major improvements
migrate diff and db execute are now Generally Available!

We released two new Preview CLI commands in version 3.9.0prisma migrate diff and prisma db execute – to enable our users to create and understand migrations and build their workflows using the commands.

We're proud to announce that the commands are now Generally Available and can now be used without the --preview-feature flag. 🎉

The prisma migrate diff command creates a diff of your database schema, Prisma schema file, or the migration history. All you have to do is feed the command with a schema from state and a schema to state to get an SQL script or human-readable diff.

In addition to prisma migrate diff, prisma db execute is used to execute SQL scripts against a database. You can directly execute prisma migrate diff's output using prisma db execute --stdin.

Both commands are non-interactive, so it's possible to build many new workflows such as forward and backward migrations with some automation tooling. Take a look at our documentation to learn some of the popular workflows these commands unlock:

Let us know what tools, automation, and scripts you build using these commands.

SQL Server index clustering (Preview)

In version 3.5.0, we introduced the extendedIndexes Preview feature which we have constantly been adding new configuration options for indexes. In this release, we added support for enabling or disabling index/constraint clustering in SQL Server.

By default, indexes will be clustered by default. You can update this in your schema as follows to disable index clustering:

datasource db {
  provider = "sqlserver"
  url      = env("DATABASE_URL")
}

generator client {
  provider        = "prisma-client-js"
  previewFeatures = ["extendedIndexes"]
}

model Post {
  id      Int     @&#8203;default(autoincrement()) @&#8203;id(clustered: false)
  title   String
  content String?
}

The following SQL will be generated in your migration when you run prisma migrate dev

CREATE TABLE [Post] (
  id INT NOT NULL,
  [title] VARCHAR(255) NOT NULL,
  [content] NVARCHAR(1000),
  CONSTRAINT [Post_pkey] PRIMARY KEY NONCLUSTERED (id)
)

If you've enabled the extendedIndexes Preview feature, this is potentially a breaking change. Refer to our documentation to learn how you can upgrade from a previous version.

Updated native types for CockroachDB (Preview)

We have revamped the native types available in the CockroachDB connector. We initially re-used the PostgreSQL native types because they were close enough, but we have now adapted our list of the supported native types to match what CockroachDB supports.

If you are already using CockroachDB in your project, you can run prisma db pull to update all the native types in your Prisma schema. Refer to our documentation for the complete list of all CockroachDB native types.

OpenSSL 3.0 Support

We're excited to announce that version 3.13.0 now supports OpenSSL 3.0. Operating systems such as Ubuntu 22.04 default to OpenSSL 3.0, and when running prisma generate, you would run into the following error:

Error: Unknown binaryTarget debian-openssl-3.0.x

If you've run into a similar error, bump up to the latest Prisma version and give it another try!

Fixes and improvements
Prisma Client
Prisma
Language tools (e.g. VS Code)
Prisma Engines
Credits

Huge thanks to @​ever0de, @​jacobhq, @​dkantereivin, @​CommanderRoot for helping!

💼 We're hiring!

If you're interested in joining our growing team to help empower developers to build data-intensive applications, Prisma is the place for you.

We're looking for a Technical Support Engineer and Senior Software Engineer (Prisma Data Platform).

Feel free to read through the job descriptions and apply using the links provided.

📺 Join us for another "What's new in Prisma" livestream

Learn about the latest release and other news from the Prisma community by joining us for another "What's new in Prisma" livestream.

The stream takes place on YouTube on Thursday, April 28 at 5 pm Berlin | 8 am San Francisco.

v3.12.0

Compare Source

Today, we are excited to share the 3.12.0 stable release 🎉

🌟 Help us spread the word about Prisma by starring the repo or tweeting about the release. 🌟

Major improvements and new features

MongoDB is now Generally Available

If you’ve been using MongoDB since it was in Preview, we'd like to say: Thank you! Your testing and feedback has been essential during the preview phase, and our MongoDB support is much better because of it.

Today we’re proud to announce that MongoDB is now stable and production-ready. After upgrading to 3.12.0, you can remove the MongoDB preview flag in your schema:

 datasource db {
   provider = "mongodb"
   url      = env("DATABASE_URL")
 }

 generator client {
   provider        = "prisma-client-js"
-  previewFeatures = ["mongoDb"]
 }

We’ve been working hard towards this day ever since we launched MongoDB in Preview in July 2021.

Here are some of the feature highlights we developed over this period:

  • Expressive and type-safe operations for querying MongoDB embedded documents
  • Thorough introspection support for using Prisma with existing MongoDB databases
  • Declarative index management right from your Prisma Schema with db push
  • Powerful raw query APIs to help you incrementally migrate to Prisma

You can learn about these features in the release blog post, and more, in our freshly brewed MongoDB Guide. For newcomers to Prisma with MongoDB, we recommend you check out our Getting Started Guide.

To celebrate this milestone, we invite you to join Prisma’s MongoDB Launch Week starting on April 25th. Enjoy a jam-packed week of exclusive workshops with plenty of opportunities to win free MongoDB Atlas credits and swag. It’s free to sign-up and available anywhere you have an internet connection.

🚨 Please be aware that we made a few breaking changes to tie up loose ends before General Availability:

We made some changes in the 3.11.1 patch release in case you missed it.

Index support on composite type fields

We also added support for adding indexes on embedded document fields in MongoDB. This means that you can now define a normal, unique, or full-text index in your schema.

type Address {
  street String
  number Int
}

model User {
  id      Int     @&#8203;id
  email   String
  address Address

  @&#8203;@&#8203;index([email, address.number])  /// normal index
  @&#8203;@&#8203;unique([email, address.street])  /// unique index
  @&#8203;@&#8203;fulltext([email, address.street]) /// full-text index
}

Note: Prisma Client does not yet fully support the feature for now. This will be rolled out in a future release.

Improved Connection Pooling Resiliency

In 3.12.0, we busted a ghost that has been bugging teams since the early days of the Prisma ORM. Under certain amounts of load, some people reported that the connection pool would sometimes drop connections or deadlock and not recover.

After many sightings and a lot of head-scratching, we were finally able to reproduce the issue. This allowed us to narrow down the problem to one of our dependencies and fix the problem.

To read the nitty gritty details of the problem and our solution, check out this issue.

Fixes and improvements

Prisma Client
Prisma
Prisma Migrate
Language tools (e.g. VS Code)
Prisma Engines

Credits

Huge thanks to @​ever0de, @​chronotc, @​hayes, @​maddhruv, @​jasimon, @​codesee-maps[bot], @​andyrichardson, @​xnerhu, @​Josh-a-e, @​dusandz for helping!

💼 We're hiring!

If you're interested in joining our growing team to help empower developers build data-intensive applications, Prisma is the place for you.

We're looking for a Developer Success Engineer and Back-end Engineer: Prisma Data Platform.

Feel free to read through the job descriptions and apply using the links provided.

📺 Join us for another "What's new in Prisma" livestream

Learn about the latest release and other news from the Prisma community by joining us for another "What's new in Prisma" livestream.

The stream takes place on YouTube on Thursday, April 7 at 5 pm Berlin | 8 am San Francisco.

v3.11.1

Compare Source

Today, we are issuing the 3.11.1 patch release.

MongoDB (Preview)

Breaking: Filters no longer return undefined fields by default

In 3.11.1, we've changed what data is returned when filtering MongoDB documents on undefined fields. The new rule is that undefined fields are excluded by default unless explicitly filtered for. This allows you to query for undefined and null values separately.

Let's take a look at a concrete example. Given the following Prisma schema:

model Address {
    id     Int    @&#8203;id @&#8203;map("_id")
    city   String
    street String? // Note that street is optional
}

For Mongo, optional fields can either be null or undefined (absent). The following documents are all valid for the schema above:

{ "_id": 1, "city": "San Fransisco", "street": "Market st." }
{ "_id": 2, "city": "Seattle", "street": null }
{ "_id": 3, "city": "Chicago" }

Prior to 3.11.1, if you queried for where: { street: null }, you'd get _id: 2 and _id: 3. In 3.11.1, you'll only get _id: 2. The ability to also query for the missing fields has also been added. For details, refer to the new isSet below to learn more.

There are a few exceptions to this new default:

  • A having filter on an aggregated field will return undefined fields. This is because aggregation on undefined fields yields null, not undefined, thus matching the filter.
  • Filters on undefined to-many relations (e.g., the backing array of a many-to-many is undefined) will currently include those relations in the result set.

New isSet filter operation

To compensate for missing fields on documents no longer being returned by the filters above, we’ve added a new isSet: bool filter. This filter can be used to include fields that are undefined on documents.

Using the example above, to include the undefined fields, you can use an OR:

await prisma.address.findMany({
  where: {
    OR: [
      { street: { isSet: false } },
      { street: null }
    ]
  }
})

The isSet operation has been added to all scalar and embedded fields that are optional.

New unset operation

In 3.11.1, you can also remove a field with the unset ope


Configuration

📅 Schedule: "before 12pm on Sunday" (UTC).

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

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.


  • If you want to rebase/retry this PR, click this checkbox.

This PR has been generated by WhiteSource Renovate. View repository job log here.

@renovate renovate bot force-pushed the renovate/all-minor-patch branch 6 times, most recently from ea581fa to f8a3e41 Compare April 4, 2022 19:21
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 3 times, most recently from 1074a00 to 79a27ef Compare April 11, 2022 19:51
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 5 times, most recently from 0e60d22 to 220bcd0 Compare April 18, 2022 19:53
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 14 times, most recently from d494016 to c701745 Compare April 29, 2022 17:03
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 2 times, most recently from 0e18cc0 to cfe8338 Compare May 1, 2022 22:19
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 3 times, most recently from 4b34333 to e91a2f7 Compare May 9, 2022 20:11
@renovate renovate bot force-pushed the renovate/all-minor-patch branch 3 times, most recently from a110188 to bc44a81 Compare May 12, 2022 21:58
@renovate renovate bot force-pushed the renovate/all-minor-patch branch from bc44a81 to 8ef460f Compare May 13, 2022 11:05
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant