Update dependency kysely to ^0.29.0 #964

Open
renovate-bot wants to merge 1 commit from renovate/kysely into main
Collaborator

This PR contains the following updates:

Package Change Age Confidence
kysely (source) ^0.28.0 → ^0.29.0 age confidence

Release Notes

kysely-org/kysely (kysely)

v0.29.7: 0.29.7

Compare Source

Hey 👋

A small batch of bug fixes. Please report any issues. 🤞😰🤞

Controlled transactions get fixes for connection leaks, shared completion state, and commands racing with ongoing queries:

  • Commit, rollback, and savepoint commands now wait for ongoing queries and streams to finish.
  • Close or exhaust active streams before awaiting these commands.
  • A failed rollback now releases the connection and marks the transaction as rolled back.

🚀 Features

🐞 Bugfixes

PostgreSQL 🐘
MSSQL 🥅

📖 Documentation

📦 CICD & Tooling

⚠️ Breaking Changes

🐤 New Contributors

What's Changed

Full Changelog: https://github.com/kysely-org/kysely/compare/v0.29.6...v0.29.7

v0.29.6: 0.29.6

Compare Source

Hey 👋

A small batch of bug fixes. Please report any issues. 🤞😰🤞

🚀 Features

🐞 Bugfixes

PostgreSQL 🐘 / SQLite 📘

📖 Documentation

📦 CICD & Tooling

⚠️ Breaking Changes

🐤 New Contributors

What's Changed

Full Changelog: https://github.com/kysely-org/kysely/compare/v0.29.5...v0.29.6

v0.29.5: 0.29.5

Compare Source

Hey 👋

A small batch of bug fixes. Please report any issues. 🤞😰🤞

TypeScript 7 is allowing for deeper computations which now cause way more instantiations and wall clock times in various scenarios. We're diving deep into our types and finding optimizations. In this version @​koskimas brought some nice wins for builder vs. builder assignability checks.

We're also revamping the docs site, working on style, message and usefulness. Swing by our Discord and share your opinions/ideas. We got docs->apidocs search now. The playground is back supporting short links and will allow saving short links very soon.

🚀 Features

🐞 Bugfixes

📖 Documentation

📦 CICD & Tooling

⚠️ Breaking Changes

🐤 New Contributors

What's Changed

Full Changelog: https://github.com/kysely-org/kysely/compare/v0.29.4...v0.29.5

v0.29.4: 0.29.4

Compare Source

Hey 👋

A small batch of bug fixes. Please report any issues. 🤞😰🤞

🚀 Features

🐞 Bugfixes

PostgreSQL 🐘
SQLite 📘
  • fix(sqlite): returning clauses wrongfuly output after order by and limit in delete queries. by @​igalklebanov in #​1946

📖 Documentation

📦 CICD & Tooling

⚠️ Breaking Changes

🐤 New Contributors

What's Changed

Full Changelog: https://github.com/kysely-org/kysely/compare/v0.29.3...v0.29.4

v0.29.3: 0.29.3

Compare Source

Hey 👋

A small batch of bug fixes. Please report any issues. 🤞😰🤞

🚀 Features

🐞 Bugfixes

PostgreSQL 🐘 / MSSQL 🥅

📖 Documentation

📦 CICD & Tooling

⚠️ Breaking Changes

PostgreSQL 🐘
  • PostgreSQL migrations now use session-level advisory locks, including when transactions are enabled. This is incompatible with PgBouncer transaction pooling and other transaction-mode connection poolers. Run migrations through a direct connection, session pooling, or custom migration locking. Otherwise, migration locks can remain held on pooled connections and block subsequent migration runs. See #​1919 and #​2200.

🐤 New Contributors

What's Changed

Full Changelog: https://github.com/kysely-org/kysely/compare/v0.29.2...v0.29.3

v0.29.2: 0.29.2

Compare Source

Hey 👋

A small batch of bug fixes. Please report any issues. 🤞😰🤞

🚀 Features

🐞 Bugfixes

📖 Documentation

📦 CICD & Tooling

⚠️ Breaking Changes

🐤 New Contributors

What's Changed

Full Changelog: https://github.com/kysely-org/kysely/compare/v0.29.1...v0.29.2

v0.29.1: 0.29.1

Compare Source

Hey 👋

A small batch of bug fixes. Please report any issues. 🤞😰🤞

🚀 Features

🐞 Bugfixes

📖 Documentation

📦 CICD & Tooling

⚠️ Breaking Changes

🐤 New Contributors

What's Changed

Full Changelog: https://github.com/kysely-org/kysely/compare/v0.29.0...v0.29.1

v0.29.0: 0.29.0

Compare Source

Hey 👋

This one's a banger! 💥 💥 💥

We got $pickTables, $omitTables compile-time helpers to narrow the world view of downstream queries, cutting down on compilation complexity/time while at it!

const results = await db
  .$pickTables<'person' | 'pet'>() // <----- now `DB` is only { person: {...}, pet: {...} } for following methods.
  .selectFrom('person')
  .innerJoin('pet', 'pet.owner_id', 'person.id')
  .selectAll()
  .execute()

const results = await db
  .$omitTables<'toy'>() // <----- now `DB` doesn't have a "toy" table description for following methods.
  .selectFrom('person')
  .innerJoin('pet', 'pet.owner_id', 'person.id')
  .selectAll()
  .execute()

We got a new ReadonlyKysely<DB> helper type that turns your instance into a compile-time readonly instance!

import { Kysely } from 'kysely'
import type { ReadonlyKysely } from 'kysely/readonly'

export const db = new Kysely<Database>({...}) as never as ReadonlyKysely<Database>

db.selectFrom('person').selectAll() // no problem.
db.selectNoFrom(sql`now()`.as('now')) // no problem.

db.deleteFrom('person') // compilation error + deprecation!
db.insertInto('person').values({...}) // compilation error + deprecation!
db.mergeInto('person')...  // compilation error + deprecation!
db.updateTable('person').set('first_name', 'Timmy') // compilation error + deprecation!
sql`...`.execute(db) // compilation error!
// etc. etc.

We got a brand new PGlite dialect. With it comes a new supportsMultipleConnections adapter flag that uses a new centralized connection mutex when false - should help simplify all SQLite dialects out here!

import { PGlite } from '@electric-sql/pglite'
import { Kysely, PGliteDialect } from 'kysely'

const db = new Kysely<DB>({
  // ...
  dialect: new PGliteDialect({
    pglite: new PGlite(),
  }),
  // ...
})

We got $narrowType supporting nested narrowing and discriminated unions!

db.selectFrom('person_metadata')
  .select(['discriminatedUnionProfile']) 
  // output type inferred as:
  //
  // {
  //   discriminatedUnionProfile: {
  //     auth:
  //       | { type: 'token'; token: string }
  //       | { type: 'session'; session_id: string }
  //     tags: string[]
  //   }
  // }[]
  .$narrowType<{ discriminatedUnionProfile: { auth: { type: 'token' } } }>()
  // output type narrowed to:
  // 
  // {
  //   discriminatedUnionProfile: {
  //     auth: { type: 'token'; token: string }
  //     tags: string[]
  //   }
  // }[]
  .execute()

We got web standards driven query cancellation support. Pass an abort signal to execute* methods and similar. Pick between different inflight query abort strategies - ignore the query, cancel it on the database side or even kill the session on the database side.

  import { Kysely, PostgresDialect } from 'kysely'
  import { Client, ... } from 'pg'

  const db = new Kysely<Database>({
    dialect: new PostgresDialect({
      // ...
      controlClient: Client, // optional, for out-of-pool connections for database side query aborts.
      // ...
    })
  })

  const options = { signal: AbortSignal.timeout(3_000) } // throw abort/timeout errors and ignore query reuslts

  query.execute(options)
  query.stream(options)
  sql`...`.execute(db, options)
  db.executeQuery(compiledQuery, options)
  // etc. etc.

  query.execute({ ...options, inflightQueryAbortStrategy: 'cancel query' }) // also cancel query database side
  query.execute({ ...options, inflightQueryAbortStrategy: 'kill session' }) // also kill session database side

We got SafeNullComparisonPlugin to flip (in)equality operators to is and is not when right hand side argument is null.

import { Kysely, SafeNullComparisonPlugin } from 'kysely'

const db = new Kysely<DB>({
  // ...
  plugins: [new SafeNullComparisonPlugin()],
  // ...
})

db.selectFrom('pet')
  .where('name', '=', null) // outputs: "name" is null
  .where('owner_id', '!=', null) // outputs: "owner_id" is not null
  .selectAll()

We got a new shouldParse(value, path) option in ParseJSONResultsPlugin for granular control of what gets JSON.parse'd and what stays a string using JSON paths.

import { JSONParseResultsPlugin } from 'kysely'

db.selectFrom('person')
  .select((eb) => jsonArrayFrom(
	  eb.selectFrom('pet')
      .where('pet.owner_id', '=', 'person.id')
 	    .selectAll()
  ).as('pets'))
  .withPlugin(new JSONParseResultsPlugin({ 
    shouldParse: (_value, path) => {
      // parse only the pets array
      if (path.endsWith('."pets"')) {
        return true
      }
    
      return false
    } 
  }))

🚀 Features

PostgreSQL 🐘 / MySQL 🐬
PostgreSQL 🐘 / MSSQL 🥅
PostgreSQL 🐘
MySQL 🐬
MSSQL 🥅
PGlite 🟨

🐞 Bugfixes

📖 Documentation

📦 CICD & Tooling

⚠️ Breaking Changes

  • Migrator, FileMigrationProvider and other migration related things are now exported from 'kysely/migration'. Importing from 'kysely' will provide an informative error message at compilation time.

    -import { Migrator, FileMigrationProvider } from 'kysely'
    +import { Migrator, FileMigrationProvider } from 'kysely/migration'
    
  • Minimum TypeScript version is now 5.4. Versions 5.3 and older will get a very aggressive compilation error.

  • The library no longer ships CommonJS files. Use a Node.js version that supports require(esm), or use dynamic imports. ES Modules files have moved from /dist/esm/ to /dist/.

  • TypeScript build target was bumped to 'es2023'.

  • sql.value and sql.literal were removed after spending a long time in deprecation. Use sql.val and sql.lit instead.

  • db.executeQuery's queryId 2nd argument has been replaced with options?: AbortableQueryOptions after spending a long time in deprecation.

  • QueryResult.numUpdatedOrDeletedRows has been removed after spending a long time in deprecation. Dialects that use it need to be updated to use QueryResult.numAffectedRows instead.

  • UniqueConstraintNode.columns widened from ReadonlyArray<ColumnNode> to ReadonlyArray<OperationNode>.

  • ExpressionBuilder.withSchema has been removed after spending a long time in deprecation.

  • DatabaseIntrospector.getMetadata has been removed after spending a long time in deprecation. Use DatabaseIntrospector.getTables instead.

  • MssqlDialectConfig.Tedious.resetConnectionOnRelease has been removed after spending a long time in deprecation. Use MssqlDialectConfig.resetConnectionsOnRelease instead.

  • MssqlDialectConfig.Tarn.options.validateConnections has been removed after spending a long time in deprecation. Use MssqlDialectConfig.validateConnections instead.

  • InsertQueryNode.ignore has been removed after spending a long time in deprecation. Use InsertQueryNode.orAction instead.

  • PrimaryConstraintNode has been removed after spending a long time in deprecation. Use PrimaryKeyConstraintNode instead.

  • DropTablexNodeParams has been removed after spending a long time in deprecation. Use DropTableNodeParams instead.

🐤 New Contributors

Full Changelog: https://github.com/kysely-org/kysely/compare/v0.28.17...v0.29.0

v0.28.18: 0.28.18

Compare Source

Hey 👋

A small batch of bug fixes. Please report any issues. 🤞😰🤞

This maintenance release backports bug fixes and documentation improvements from the 0.29 line.

Controlled transactions get fixes for connection leaks, shared completion state, and commands racing with ongoing queries:

  • Commit, rollback, and savepoint commands now wait for ongoing queries and streams to finish.
  • Close or exhaust active streams before awaiting these commands.
  • A failed rollback now releases the connection and marks the transaction as rolled back.

PostgreSQL and MSSQL now use session-level migration locks, including with disableTransactions: true. PostgreSQL migrations through PgBouncer transaction pooling need a direct connection, session pooling, or custom migration locking.

🚀 Features

🐞 Bugfixes

PostgreSQL 🐘 / MSSQL 🥅
PostgreSQL 🐘 / SQLite 📘

On-conflict WHERE predicates now use column select types, including for columns that cannot be updated.

PostgreSQL 🐘
SQLite 📘
MSSQL 🥅

📖 Documentation

📦 CICD & Tooling

⚠️ Breaking Changes

🐤 New Contributors

What's Changed

Full Changelog: https://github.com/kysely-org/kysely/compare/v0.28.17...v0.28.18


Configuration

📅 Schedule: (UTC)

  • Branch creation
    • At any time (no schedule defined)
  • 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.


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

This PR has been generated by Mend Renovate CLI.

This PR contains the following updates: | Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) | |---|---|---|---| | [kysely](https://kysely.dev) ([source](https://github.com/kysely-org/kysely)) | [`^0.28.0` → `^0.29.0`](https://renovatebot.com/diffs/npm/kysely/0.28.17/0.29.7) | ![age](https://developer.mend.io/api/mc/badges/age/npm/kysely/0.29.7?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/kysely/0.28.17/0.29.7?slim=true) | --- ### Release Notes <details> <summary>kysely-org/kysely (kysely)</summary> ### [`v0.29.7`](https://github.com/kysely-org/kysely/releases/tag/v0.29.7): 0.29.7 [Compare Source](https://github.com/kysely-org/kysely/compare/v0.29.6...v0.29.7) Hey 👋 A small batch of bug fixes. Please report any issues. 🤞😰🤞 Controlled transactions get fixes for connection leaks, shared completion state, and commands racing with ongoing queries: - Commit, rollback, and savepoint commands now wait for ongoing queries and streams to finish. - Close or exhaust active streams before awaiting these commands. - A failed rollback now releases the connection and marks the transaction as rolled back. #### 🚀 Features #### 🐞 Bugfixes - fix: release controlled transaction connection when begin fails by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2080](https://github.com/kysely-org/kysely/pull/2080) - fix: share completion state between controlled transaction handles by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2090](https://github.com/kysely-org/kysely/pull/2090) - fix: release controlled transaction connection when rollback fails by [@&#8203;B4nan](https://github.com/B4nan) in [#&#8203;2136](https://github.com/kysely-org/kysely/pull/2136) - fix: serialize controlled transaction commands with queries by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2081](https://github.com/kysely-org/kysely/pull/2081) ##### PostgreSQL 🐘 - fix(postgres): release the client when destroyed while acquiring a connection by [@&#8203;abebelagua](https://github.com/abebelagua) & [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2088](https://github.com/kysely-org/kysely/pull/2088) ##### MSSQL 🥅 - fix(mssql): escape `jsonBuildObject` keys. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2078](https://github.com/kysely-org/kysely/pull/2078) - fix(mssql): escape JSON in `jsonBuildObject` by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2079](https://github.com/kysely-org/kysely/pull/2079) #### 📖 Documentation - docs: add Langfuse to the built-into proof wall by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2054](https://github.com/kysely-org/kysely/pull/2054) - docs: add TrueForge to the built-into proof wall by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2055](https://github.com/kysely-org/kysely/pull/2055) - docs: add Open Mercato to the built-into proof wall by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2056](https://github.com/kysely-org/kysely/pull/2056) - docs: make homepage title descriptive by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2058](https://github.com/kysely-org/kysely/pull/2058) - fix(site): preload the homepage video poster with high priority by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2059](https://github.com/kysely-org/kysely/pull/2059) - fix(site): stabilize demo video dimensions by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2060](https://github.com/kysely-org/kysely/pull/2060) - docs: add a default social preview card by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2061](https://github.com/kysely-org/kysely/pull/2061) - docs: share the homepage description and refresh production examples by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2062](https://github.com/kysely-org/kysely/pull/2062) - docs: add descriptions to non-example pages by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2063](https://github.com/kysely-org/kysely/pull/2063) - fix(site): stabilize search label and center shortcut keys by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2064](https://github.com/kysely-org/kysely/pull/2064) - fix(site): serve Markdown for explicit Accept requests by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2066](https://github.com/kysely-org/kysely/pull/2066) - fix(site): expose agent documentation discovery hint by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2065](https://github.com/kysely-org/kysely/pull/2065) - fix(site): add agent discovery hints to Markdown pages by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2067](https://github.com/kysely-org/kysely/pull/2067) - fix(site): remove HTML comments from generated Markdown by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2068](https://github.com/kysely-org/kysely/pull/2068) - fix(site): include category pages in agent documentation by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2069](https://github.com/kysely-org/kysely/pull/2069) - fix(site): reduce homepage Markdown size by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2071](https://github.com/kysely-org/kysely/pull/2071) - docs(site): improve API reference discovery by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2072](https://github.com/kysely-org/kysely/pull/2072) - docs(site): publish robots.txt with sitemap by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2074](https://github.com/kysely-org/kysely/pull/2074) - docs(site): advertise agent index in homepage Link header by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2075](https://github.com/kysely-org/kysely/pull/2075) - docs(site): declare content usage preferences by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2076](https://github.com/kysely-org/kysely/pull/2076) - docs: audit the proof wall and refresh usage evidence by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2085](https://github.com/kysely-org/kysely/pull/2085) - fix(site): serve Markdown 404 responses to agents by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2089](https://github.com/kysely-org/kysely/pull/2089) - docs: add software identity and maintainer contact structured data by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2091](https://github.com/kysely-org/kysely/pull/2091) - docs: declare Open Graph website type by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2092](https://github.com/kysely-org/kysely/pull/2092) - docs: link organization identity profiles in JSON-LD by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2093](https://github.com/kysely-org/kysely/pull/2093) - docs: add LinkedIn to organization structured data by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2095](https://github.com/kysely-org/kysely/pull/2095) - docs: generate agent discovery catalogs by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2094](https://github.com/kysely-org/kysely/pull/2094) - docs: compress testimonial avatars by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2098](https://github.com/kysely-org/kysely/pull/2098) - docs: render each testimonial once by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2099](https://github.com/kysely-org/kysely/pull/2099) - perf(site): defer Prism until documentation is loaded by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2100](https://github.com/kysely-org/kysely/pull/2100) - perf(site): preload search when the browser is idle by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2101](https://github.com/kysely-org/kysely/pull/2101) - fix(site): improve hero audit text contrast by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2102](https://github.com/kysely-org/kysely/pull/2102) - docs(site): add A2A JavaScript SDK to proof wall by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2103](https://github.com/kysely-org/kysely/pull/2103) - fix(site): preserve testimonial avatar aspect ratios by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2106](https://github.com/kysely-org/kysely/pull/2106) - fix(site): enlarge theme toggle touch targets by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2105](https://github.com/kysely-org/kysely/pull/2105) - fix(site): show the demo poster before hydration by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2107](https://github.com/kysely-org/kysely/pull/2107) - fix(site): improve light-mode accent contrast by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2108](https://github.com/kysely-org/kysely/pull/2108) - perf(site): preload the demo poster before stylesheets by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2112](https://github.com/kysely-org/kysely/pull/2112) - perf(site): externalize proof-wall logo artwork by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2114](https://github.com/kysely-org/kysely/pull/2114) - fix(site): show brand names while the logo sprite loads by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2116](https://github.com/kysely-org/kysely/pull/2116) - docs: fix PostgreSQL pool in plugin example by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2117](https://github.com/kysely-org/kysely/pull/2117) - docs: consolidate Deno guidance in getting started by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2118](https://github.com/kysely-org/kysely/pull/2118) - docs: enable Bun SQLite with better-sqlite3 by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2124](https://github.com/kysely-org/kysely/pull/2124) - docs: describe the `LogEvent` union by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2121](https://github.com/kysely-org/kysely/pull/2121) - docs: qualify PGlite type generation support by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2120](https://github.com/kysely-org/kysely/pull/2120) - docs: add kysely-typegen to type generators by [@&#8203;theoludwig](https://github.com/theoludwig) & [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2126](https://github.com/kysely-org/kysely/pull/2126) - docs(site): remove duplicate intro help paragraph by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2133](https://github.com/kysely-org/kysely/pull/2133) - fix(site): respect reduced motion and add demo playback control by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2130](https://github.com/kysely-org/kysely/pull/2130) - docs: clarify shared pool and database instance lifecycles by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2143](https://github.com/kysely-org/kysely/pull/2143) #### 📦 CICD & Tooling - ci: replace llms text comparison with local afdocs checks by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2070](https://github.com/kysely-org/kysely/pull/2070) - chore(deps): bump afdocs to 0.22.2 by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2087](https://github.com/kysely-org/kysely/pull/2087) - ci: use non-Docker Hub images for PostgreSQL and MySQL. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2127](https://github.com/kysely-org/kysely/pull/2127) - ci: add registry fallbacks and reuse the SQL Server image by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2140](https://github.com/kysely-org/kysely/pull/2140) - chore: bump deps. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2142](https://github.com/kysely-org/kysely/pull/2142) #### ⚠️ Breaking Changes #### 🐤 New Contributors - [@&#8203;theoludwig](https://github.com/theoludwig) made their first contribution in [#&#8203;2126](https://github.com/kysely-org/kysely/pull/2126) - [@&#8203;abebelagua](https://github.com/abebelagua) made their first contribution in [#&#8203;2088](https://github.com/kysely-org/kysely/pull/2088) #### What's Changed **Full Changelog**: <https://github.com/kysely-org/kysely/compare/v0.29.6...v0.29.7> ### [`v0.29.6`](https://github.com/kysely-org/kysely/releases/tag/v0.29.6): 0.29.6 [Compare Source](https://github.com/kysely-org/kysely/compare/v0.29.5...v0.29.6) Hey 👋 A small batch of bug fixes. Please report any issues. 🤞😰🤞 #### 🚀 Features #### 🐞 Bugfixes ##### PostgreSQL 🐘 / SQLite 📘 - fix: allow immutable columns in `doUpdateSet`'s `where`. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2043](https://github.com/kysely-org/kysely/pull/2043) #### 📖 Documentation - feat(site): grow the proof wall from npm's dependents (Cypress, Canton, Tailor, Supabase Lite) + verify every pin by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1985](https://github.com/kysely-org/kysely/pull/1985) - Update link to Migrator API docs by [@&#8203;ardouglass](https://github.com/ardouglass) in [#&#8203;1991](https://github.com/kysely-org/kysely/pull/1991) #### 📦 CICD & Tooling - chore: bumps dependencies. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2045](https://github.com/kysely-org/kysely/pull/2045) #### ⚠️ Breaking Changes #### 🐤 New Contributors - [@&#8203;ardouglass](https://github.com/ardouglass) made their first contribution in [#&#8203;1991](https://github.com/kysely-org/kysely/pull/1991) #### What's Changed **Full Changelog**: <https://github.com/kysely-org/kysely/compare/v0.29.5...v0.29.6> ### [`v0.29.5`](https://github.com/kysely-org/kysely/releases/tag/v0.29.5): 0.29.5 [Compare Source](https://github.com/kysely-org/kysely/compare/v0.29.4...v0.29.5) Hey 👋 A small batch of bug fixes. Please report any issues. 🤞😰🤞 TypeScript 7 is allowing for deeper computations which now cause way more instantiations and wall clock times in various scenarios. We're diving deep into our types and finding optimizations. In this version [@&#8203;koskimas](https://github.com/koskimas) brought some nice wins for builder vs. builder assignability checks. We're also revamping the docs site, working on style, message and usefulness. Swing by our Discord and share your opinions/ideas. We got docs->apidocs search now. The playground is back supporting short links and will allow saving short links very soon. #### 🚀 Features #### 🐞 Bugfixes - fix infinite type check recursion by [@&#8203;koskimas](https://github.com/koskimas) in [#&#8203;1960](https://github.com/kysely-org/kysely/pull/1960) - Add missing beforeThrow calls in getInflightQueryAbortHandler by [@&#8203;lourd](https://github.com/lourd) in [#&#8203;1971](https://github.com/kysely-org/kysely/pull/1971) #### 📖 Documentation - Fix typo in `CreateTypeBuilder.asEnum` docstring by [@&#8203;anonpay-sh](https://github.com/anonpay-sh) in [#&#8203;1949](https://github.com/kysely-org/kysely/pull/1949) - chore: revamp docs hero page. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1959](https://github.com/kysely-org/kysely/pull/1959) - fix(site): various issues with stats section. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1966](https://github.com/kysely-org/kysely/pull/1966) - chore(site): replace most text proof with logos. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1968](https://github.com/kysely-org/kysely/pull/1968) - feat(site): migrate to pagefind for cross-site search we own. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1972](https://github.com/kysely-org/kysely/pull/1972) - chore(site): drop self-narrating captions, make proof arrows a standing cue by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1973](https://github.com/kysely-org/kysely/pull/1973) - feat(site): grow the proof wall (Replicas, EmbedPDF) + fix production hover by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1974](https://github.com/kysely-org/kysely/pull/1974) - feat(site): add AirTrail, bknd, Civitai, Corsair.dev, Hot Updater, Profilarr and Tunarr to the proof wall. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1975](https://github.com/kysely-org/kysely/pull/1975) - feat(site): proof-strength gauges, query-module evidence, and new wall names by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1976](https://github.com/kysely-org/kysely/pull/1976) - feat(site): explain the proof gauge behind a (?) on the production wall by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1977](https://github.com/kysely-org/kysely/pull/1977) - feat(site): align docs code blocks with the landing page's VS Code themes by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1978](https://github.com/kysely-org/kysely/pull/1978) #### 📦 CICD & Tooling - chore: bump deps. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1979](https://github.com/kysely-org/kysely/pull/1979) - chore: bump github actions. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1980](https://github.com/kysely-org/kysely/pull/1980) #### ⚠️ Breaking Changes #### 🐤 New Contributors - [@&#8203;anonpay-sh](https://github.com/anonpay-sh) made their first contribution in [#&#8203;1949](https://github.com/kysely-org/kysely/pull/1949) - [@&#8203;lourd](https://github.com/lourd) made their first contribution in [#&#8203;1971](https://github.com/kysely-org/kysely/pull/1971) #### What's Changed **Full Changelog**: <https://github.com/kysely-org/kysely/compare/v0.29.4...v0.29.5> ### [`v0.29.4`](https://github.com/kysely-org/kysely/releases/tag/v0.29.4): 0.29.4 [Compare Source](https://github.com/kysely-org/kysely/compare/v0.29.3...v0.29.4) Hey 👋 A small batch of bug fixes. Please report any issues. 🤞😰🤞 #### 🚀 Features #### 🐞 Bugfixes ##### PostgreSQL 🐘 - fix: fix postgres password not being passed to control client by [@&#8203;CakeWithDivinity](https://github.com/CakeWithDivinity) & [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1944](https://github.com/kysely-org/kysely/pull/1944) ##### SQLite 📘 - fix(sqlite): returning clauses wrongfuly output after order by and limit in delete queries. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1946](https://github.com/kysely-org/kysely/pull/1946) #### 📖 Documentation #### 📦 CICD & Tooling - chore: bump dependencies. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1945](https://github.com/kysely-org/kysely/pull/1945) #### ⚠️ Breaking Changes #### 🐤 New Contributors - [@&#8203;CakeWithDivinity](https://github.com/CakeWithDivinity) made their first contribution in [#&#8203;1944](https://github.com/kysely-org/kysely/pull/1944) #### What's Changed **Full Changelog**: <https://github.com/kysely-org/kysely/compare/v0.29.3...v0.29.4> ### [`v0.29.3`](https://github.com/kysely-org/kysely/releases/tag/v0.29.3): 0.29.3 [Compare Source](https://github.com/kysely-org/kysely/compare/v0.29.2...v0.29.3) Hey 👋 A small batch of bug fixes. Please report any issues. 🤞😰🤞 #### 🚀 Features #### 🐞 Bugfixes ##### PostgreSQL 🐘 / MSSQL 🥅 - fix: PostgreSQL and MSSQL migrations are not running exclusively when `disableTransactions: true`. by [@&#8203;morgan-coded](https://github.com/morgan-coded) & [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1919](https://github.com/kysely-org/kysely/pull/1919) #### 📖 Documentation - docs: add kysely-durable-objects to community dialects by [@&#8203;jeffwilde](https://github.com/jeffwilde) in [#&#8203;1805](https://github.com/kysely-org/kysely/pull/1805) - docs: use new play.kysely.dev domain for the playground. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1874](https://github.com/kysely-org/kysely/pull/1874) - docs([#&#8203;1892](https://github.com/kysely-org/kysely/issues/1892)): add marshift/kysely-deno-sqlite3 to community dialects by [@&#8203;ltianyi992](https://github.com/ltianyi992) in [#&#8203;1901](https://github.com/kysely-org/kysely/pull/1901) #### 📦 CICD & Tooling - chore(deps-dev): bump tsx from 4.22.0 to 4.22.1 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1855](https://github.com/kysely-org/kysely/pull/1855) - chore(deps): bump hono from 4.12.18 to 4.12.19 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1854](https://github.com/kysely-org/kysely/pull/1854) - chore(deps): bump zizmorcore/zizmor-action from 0.5.4 to 0.5.6 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1853](https://github.com/kysely-org/kysely/pull/1853) - chore(deps): bump github/codeql-action from 4.35.4 to 4.35.5 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1850](https://github.com/kysely-org/kysely/pull/1850) - chore(deps-dev): bump [@&#8203;types/node](https://github.com/types/node) from 25.8.0 to 25.9.0 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1860](https://github.com/kysely-org/kysely/pull/1860) - chore(deps-dev): bump pg from 8.20.0 to 8.21.0 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1858](https://github.com/kysely-org/kysely/pull/1858) - chore(deps-dev): bump tsx from 4.22.1 to 4.22.3 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1863](https://github.com/kysely-org/kysely/pull/1863) - chore(deps): bump hono from 4.12.19 to 4.12.21 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1862](https://github.com/kysely-org/kysely/pull/1862) - chore(deps-dev): bump pg-cursor from 2.19.0 to 2.20.0 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1857](https://github.com/kysely-org/kysely/pull/1857) - chore(deps-dev): bump [@&#8203;types/node](https://github.com/types/node) from 25.9.0 to 25.9.1 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1866](https://github.com/kysely-org/kysely/pull/1866) - chore(ci): use pedantic `zizmor` persona. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1869](https://github.com/kysely-org/kysely/pull/1869) - chore(deps-dev): bump [@&#8203;electric-sql/pglite](https://github.com/electric-sql/pglite) from 0.4.5 to 0.4.6 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1881](https://github.com/kysely-org/kysely/pull/1881) - chore(deps): bump hono from 4.12.21 to 4.12.23 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1880](https://github.com/kysely-org/kysely/pull/1880) - chore: resolve audit vulnerabilities. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1882](https://github.com/kysely-org/kysely/pull/1882) - chore(ci): audit npm packages. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1883](https://github.com/kysely-org/kysely/pull/1883) - chore(deps-dev): bump mysql2 from 3.22.3 to 3.22.4 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1888](https://github.com/kysely-org/kysely/pull/1888) - chore(deps): bump github/codeql-action from 4.35.5 to 4.36.1 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1900](https://github.com/kysely-org/kysely/pull/1900) - chore(deps-dev): bump [@&#8203;arethetypeswrong/cli](https://github.com/arethetypeswrong/cli) from 0.18.2 to 0.18.3 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1899](https://github.com/kysely-org/kysely/pull/1899) - chore(deps): bump actions/checkout from 6.0.2 to 6.0.3 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1896](https://github.com/kysely-org/kysely/pull/1896) - chore(deps): bump step-security/harden-runner from 2.19.3 to 2.19.4 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1870](https://github.com/kysely-org/kysely/pull/1870) - chore(deps-dev): bump semver from 7.8.0 to 7.8.1 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1877](https://github.com/kysely-org/kysely/pull/1877) - chore: bump dependencies. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1920](https://github.com/kysely-org/kysely/pull/1920) - chore(deps-dev): bump [@&#8203;types/node](https://github.com/types/node) from 26.0.1 to 26.1.0 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1926](https://github.com/kysely-org/kysely/pull/1926) - chore(deps-dev): bump [@&#8203;ark/attest](https://github.com/ark/attest) from 0.56.1 to 0.56.2 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1925](https://github.com/kysely-org/kysely/pull/1925) - chore(deps-dev): bump [@&#8203;types/sinon](https://github.com/types/sinon) from 21.0.1 to 22.0.0 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1924](https://github.com/kysely-org/kysely/pull/1924) - chore(deps-dev): bump prettier from 3.9.1 to 3.9.4 by [@&#8203;dependabot](https://github.com/dependabot)\[bot] in [#&#8203;1923](https://github.com/kysely-org/kysely/pull/1923) #### ⚠️ Breaking Changes ##### PostgreSQL 🐘 - PostgreSQL migrations now use session-level advisory locks, including when transactions are enabled. This is incompatible with PgBouncer transaction pooling and other transaction-mode connection poolers. Run migrations through a direct connection, session pooling, or custom migration locking. Otherwise, migration locks can remain held on pooled connections and block subsequent migration runs. See [#&#8203;1919](https://github.com/kysely-org/kysely/pull/1919) and [#&#8203;2200](https://github.com/kysely-org/kysely/issues/2200). #### 🐤 New Contributors - [@&#8203;jeffwilde](https://github.com/jeffwilde) made their first contribution in [#&#8203;1805](https://github.com/kysely-org/kysely/pull/1805) - [@&#8203;ltianyi992](https://github.com/ltianyi992) made their first contribution in [#&#8203;1901](https://github.com/kysely-org/kysely/pull/1901) - [@&#8203;morgan-coded](https://github.com/morgan-coded) made their first contribution in [#&#8203;1919](https://github.com/kysely-org/kysely/pull/1919) #### What's Changed **Full Changelog**: <https://github.com/kysely-org/kysely/compare/v0.29.2...v0.29.3> ### [`v0.29.2`](https://github.com/kysely-org/kysely/releases/tag/v0.29.2): 0.29.2 [Compare Source](https://github.com/kysely-org/kysely/compare/v0.29.1...v0.29.2) Hey 👋 A small batch of bug fixes. Please report any issues. 🤞😰🤞 #### 🚀 Features #### 🐞 Bugfixes - fix: `$narrowType` mishandling branded types. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1851](https://github.com/kysely-org/kysely/pull/1851) #### 📖 Documentation #### 📦 CICD & Tooling #### ⚠️ Breaking Changes #### 🐤 New Contributors #### What's Changed **Full Changelog**: <https://github.com/kysely-org/kysely/compare/v0.29.1...v0.29.2> ### [`v0.29.1`](https://github.com/kysely-org/kysely/releases/tag/v0.29.1): 0.29.1 [Compare Source](https://github.com/kysely-org/kysely/compare/v0.29.0...v0.29.1) Hey 👋 A small batch of bug fixes. Please report any issues. 🤞😰🤞 #### 🚀 Features #### 🐞 Bugfixes - fix: regression in piping of plugins' result transformations. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1840](https://github.com/kysely-org/kysely/pull/1840) #### 📖 Documentation #### 📦 CICD & Tooling - ci: test node.js v26. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1841](https://github.com/kysely-org/kysely/pull/1841) - ci: harden github workflows with the help of `zizmor` scans. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1843](https://github.com/kysely-org/kysely/pull/1843) - ci: split node tests by variant. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1848](https://github.com/kysely-org/kysely/pull/1848) #### ⚠️ Breaking Changes #### 🐤 New Contributors #### What's Changed **Full Changelog**: <https://github.com/kysely-org/kysely/compare/v0.29.0...v0.29.1> ### [`v0.29.0`](https://github.com/kysely-org/kysely/releases/tag/v0.29.0): 0.29.0 [Compare Source](https://github.com/kysely-org/kysely/compare/v0.28.18...v0.29.0) Hey 👋 This one's a banger! 💥 💥 💥 We got `$pickTables`, `$omitTables` compile-time helpers to narrow the world view of downstream queries, cutting down on compilation complexity/time while at it! ```ts const results = await db .$pickTables<'person' | 'pet'>() // <----- now `DB` is only { person: {...}, pet: {...} } for following methods. .selectFrom('person') .innerJoin('pet', 'pet.owner_id', 'person.id') .selectAll() .execute() const results = await db .$omitTables<'toy'>() // <----- now `DB` doesn't have a "toy" table description for following methods. .selectFrom('person') .innerJoin('pet', 'pet.owner_id', 'person.id') .selectAll() .execute() ``` We got a new `ReadonlyKysely<DB>` helper type that turns your instance into a compile-time readonly instance! ```ts import { Kysely } from 'kysely' import type { ReadonlyKysely } from 'kysely/readonly' export const db = new Kysely<Database>({...}) as never as ReadonlyKysely<Database> db.selectFrom('person').selectAll() // no problem. db.selectNoFrom(sql`now()`.as('now')) // no problem. db.deleteFrom('person') // compilation error + deprecation! db.insertInto('person').values({...}) // compilation error + deprecation! db.mergeInto('person')... // compilation error + deprecation! db.updateTable('person').set('first_name', 'Timmy') // compilation error + deprecation! sql`...`.execute(db) // compilation error! // etc. etc. ``` We got a brand new PGlite dialect. With it comes a new `supportsMultipleConnections` adapter flag that uses a new centralized connection mutex when `false` - should help simplify all SQLite dialects out here! ```ts import { PGlite } from '@electric-sql/pglite' import { Kysely, PGliteDialect } from 'kysely' const db = new Kysely<DB>({ // ... dialect: new PGliteDialect({ pglite: new PGlite(), }), // ... }) ``` We got `$narrowType` supporting nested narrowing and discriminated unions! ```ts db.selectFrom('person_metadata') .select(['discriminatedUnionProfile']) // output type inferred as: // // { // discriminatedUnionProfile: { // auth: // | { type: 'token'; token: string } // | { type: 'session'; session_id: string } // tags: string[] // } // }[] .$narrowType<{ discriminatedUnionProfile: { auth: { type: 'token' } } }>() // output type narrowed to: // // { // discriminatedUnionProfile: { // auth: { type: 'token'; token: string } // tags: string[] // } // }[] .execute() ``` We got web standards driven query cancellation support. Pass an abort `signal` to `execute*` methods and similar. Pick between different inflight query abort strategies - ignore the query, cancel it on the database side or even kill the session on the database side. ```ts import { Kysely, PostgresDialect } from 'kysely' import { Client, ... } from 'pg' const db = new Kysely<Database>({ dialect: new PostgresDialect({ // ... controlClient: Client, // optional, for out-of-pool connections for database side query aborts. // ... }) }) const options = { signal: AbortSignal.timeout(3_000) } // throw abort/timeout errors and ignore query reuslts query.execute(options) query.stream(options) sql`...`.execute(db, options) db.executeQuery(compiledQuery, options) // etc. etc. query.execute({ ...options, inflightQueryAbortStrategy: 'cancel query' }) // also cancel query database side query.execute({ ...options, inflightQueryAbortStrategy: 'kill session' }) // also kill session database side ``` We got `SafeNullComparisonPlugin` to flip (in)equality operators to `is` and `is not` when right hand side argument is `null`. ```ts import { Kysely, SafeNullComparisonPlugin } from 'kysely' const db = new Kysely<DB>({ // ... plugins: [new SafeNullComparisonPlugin()], // ... }) db.selectFrom('pet') .where('name', '=', null) // outputs: "name" is null .where('owner_id', '!=', null) // outputs: "owner_id" is not null .selectAll() ``` We got a new `shouldParse(value, path)` option in `ParseJSONResultsPlugin` for granular control of what gets `JSON.parse`'d and what stays a string using JSON paths. ```ts import { JSONParseResultsPlugin } from 'kysely' db.selectFrom('person') .select((eb) => jsonArrayFrom( eb.selectFrom('pet') .where('pet.owner_id', '=', 'person.id') .selectAll() ).as('pets')) .withPlugin(new JSONParseResultsPlugin({ shouldParse: (_value, path) => { // parse only the pets array if (path.endsWith('."pets"')) { return true } return false } })) ``` #### 🚀 Features - feat(utils): Allow explicit undefined in Updateable type (for exactOptionalPropertyTypes support) by [@&#8203;y-hsgw](https://github.com/y-hsgw) in [#&#8203;1496](https://github.com/kysely-org/kysely/pull/1496) - feat(migrator): allow disabling transactions in migrate methods. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1517](https://github.com/kysely-org/kysely/pull/1517) - feat: add `thenRef` method in `eb.case` by [@&#8203;ericsodev](https://github.com/ericsodev) in [#&#8203;1531](https://github.com/kysely-org/kysely/pull/1531) - feat: add `whenRef(lhs, op, rhs)` in `eb.case`. by [@&#8203;iam-abdul](https://github.com/iam-abdul) in [#&#8203;1598](https://github.com/kysely-org/kysely/pull/1598) - feat: add `elseRef` in `eb.case()` by [@&#8203;iam-abdul](https://github.com/iam-abdul) in [#&#8203;1601](https://github.com/kysely-org/kysely/pull/1601) - feat: add `$pickTables`, `$omitTables` and `$extendTables`, deprecate `withTables`. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1582](https://github.com/kysely-org/kysely/pull/1582) - feat: add `SafeNullComparisonPlugin` plugin by [@&#8203;rafaelalmeidatk](https://github.com/rafaelalmeidatk) in [#&#8203;1338](https://github.com/kysely-org/kysely/pull/1338) - feat: add more control through configuration @&#8203; `ParseJSONResultsPlugin`. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1453](https://github.com/kysely-org/kysely/pull/1453) - feat: allow expressions in create/add index's `column` and `columns` functions, deprecate their `expression` functions. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1664](https://github.com/kysely-org/kysely/pull/1664) - feat: add `with(name, query)`. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1702](https://github.com/kysely-org/kysely/pull/1702) - feat: expose migrations from 'kysely/migration'. deprecate migration exports in root. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1618](https://github.com/kysely-org/kysely/pull/1618) - refactor: bump minimum TypeScript version to 4.7. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1696](https://github.com/kysely-org/kysely/pull/1696) - refactor: bump minimum TypeScript version to 4.8. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1756](https://github.com/kysely-org/kysely/pull/1756) - refactor: bump minimum TypeScript version to 4.9. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1759](https://github.com/kysely-org/kysely/pull/1759) - refactor: bump minimum TypeScript version to 5.0. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1761](https://github.com/kysely-org/kysely/pull/1761) - refactor: bump minimum TypeScript version to 5.1. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1770](https://github.com/kysely-org/kysely/pull/1770) - refactor: bump minimum TypeScript version to 5.2. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1771](https://github.com/kysely-org/kysely/pull/1771) - refactor: bump minimum TypeScript version to 5.3. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1772](https://github.com/kysely-org/kysely/pull/1772) - refactor: bump minimum TypeScript version to 5.4. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1773](https://github.com/kysely-org/kysely/pull/1773) - feat: support narrowing by deep object keys in `NarrowPartial` by [@&#8203;ethanresnick](https://github.com/ethanresnick) in [#&#8203;1667](https://github.com/kysely-org/kysely/pull/1667) - feat: add `ReadonlyKysely<DB>` helper. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;218](https://github.com/kysely-org/kysely/pull/218) - refactor: replace `requireAllProps<T>(obj)` usage with `satisfies AllProps<T>`. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1787](https://github.com/kysely-org/kysely/pull/1787) - feat: allow overriding file import function @&#8203; `FileMigrationProvider`. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1661](https://github.com/kysely-org/kysely/pull/1661) - feat: query cancellation. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1796](https://github.com/kysely-org/kysely/pull/1796) & [#&#8203;1797](https://github.com/kysely-org/kysely/pull/1797) & [#&#8203;1798](https://github.com/kysely-org/kysely/pull/1798) & [`33e60df`](https://github.com/kysely-org/kysely/commit/33e60dfa6284263173ee7e678455ad410f8bf246) & [`b739e02`](https://github.com/kysely-org/kysely/commit/b739e0240cd885091508335ce16461da258c47f6) & [`4d7064f`](https://github.com/kysely-org/kysely/commit/4d7064f199bd107213597a5965c4d673ab9880a2) - refactor: remove long deprecated things. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1799](https://github.com/kysely-org/kysely/pull/1799) - fix(ParseJSONResultsPlugin): wrap object keys in quotes. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [`1e051c8`](https://github.com/kysely-org/kysely/commit/1e051c880a028eb37552bf241b1bc750f115cbf3) ##### PostgreSQL 🐘 / MySQL 🐬 - feat(Introspect): add support for postgres & mysql foreign tables by [@&#8203;williamluke4](https://github.com/williamluke4) in [#&#8203;1494](https://github.com/kysely-org/kysely/pull/1494) ##### PostgreSQL 🐘 / MSSQL 🥅 - feat(Migrator): allow passing transactions to `Migrator`. by [@&#8203;jlucaso1](https://github.com/jlucaso1) in [#&#8203;1480](https://github.com/kysely-org/kysely/pull/1480) - feat: support IF EXISTS in DROP COLUMN by [@&#8203;shuaixr](https://github.com/shuaixr) in [#&#8203;1692](https://github.com/kysely-org/kysely/pull/1692) ##### PostgreSQL 🐘 - feat: support dropping multiple types with schema.dropType(), cascade. by [@&#8203;aantia](https://github.com/aantia) in [#&#8203;1516](https://github.com/kysely-org/kysely/pull/1516) - feat: add alter type query support. by [@&#8203;lucianolix](https://github.com/lucianolix) in [#&#8203;1363](https://github.com/kysely-org/kysely/pull/1363) - refactor(postgres): refactor: optimize table metadata parsing in PostgresIntrospector by [@&#8203;rubenferreira97](https://github.com/rubenferreira97) in [`ba89cc3`](https://github.com/kysely-org/kysely/commit/ba89cc338690f40d07f59a99a741b78a6a992f0d) ##### MySQL 🐬 - feat: allow expressions in unique constraint by [@&#8203;ericsodev](https://github.com/ericsodev) in [#&#8203;1518](https://github.com/kysely-org/kysely/pull/1518) - feat: Add support for dropping temporary tables with temporary() modifier by [@&#8203;szalonna](https://github.com/szalonna) in [#&#8203;1615](https://github.com/kysely-org/kysely/pull/1615) - feat: add `addIndex` to `CreateTableBuilder` by [@&#8203;alenap93](https://github.com/alenap93) in [#&#8203;1352](https://github.com/kysely-org/kysely/pull/1352) ##### MSSQL 🥅 - feat: add `datetime2` data type support. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1792](https://github.com/kysely-org/kysely/pull/1792) ##### PGlite 🟨 - feat: add PGlite dialect. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1510](https://github.com/kysely-org/kysely/pull/1510) #### 🐞 Bugfixes #### 📖 Documentation #### 📦 CICD & Tooling - chore: improve TypeScript benchmarks. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1757](https://github.com/kysely-org/kysely/pull/1757) - chore: add returning.bench.ts by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [`65b6ec4`](https://github.com/kysely-org/kysely/commit/65b6ec4abe15101ea2fad61e01b89fecf762ad40) - chore: enhance returning benchmarks. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [`b23085a`](https://github.com/kysely-org/kysely/commit/b23085acc23f3aeaa2764006ca327bc72919d108) - chore: add selectNoFrom benchmarks. [@&#8203;igalklebanov](https://github.com/igalklebanov) in [`8193d37`](https://github.com/kysely-org/kysely/commit/8193d3716dea0a8c0a93e882cc0450966900073e) - test: fix TypeScript 5.4.0 test following target bump to es2023. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1780](https://github.com/kysely-org/kysely/pull/1780) - chore: drop CommonJS distribution. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1782](https://github.com/kysely-org/kysely/pull/1782) - chore(ci): support rc publishes from next branch. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [`585bf60`](https://github.com/kysely-org/kysely/commit/585bf60c6d93cf01db39e196be32f12a2c8a7f01) - chore: bump dependencies. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1810](https://github.com/kysely-org/kysely/pull/1810) - chore: migrate to pnpm 11. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1811](https://github.com/kysely-org/kysely/pull/1811) - add dependabot. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [`7f98851`](https://github.com/kysely-org/kysely/commit/7f988516d414027ba658d5f3100f8eba0aa2a36d) - chore: remove npm bump in publish workflow. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [`9e0bfc0`](https://github.com/kysely-org/kysely/commit/9e0bfc0bf0f32d9a3828e4b1557efb7287ef721b) - fix(ci): better-sqlite3 node.js version mismatches since pnpm action bump. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1820](https://github.com/kysely-org/kysely/pull/1820) #### ⚠️ Breaking Changes - `Migrator`, `FileMigrationProvider` and other migration related things are now exported from `'kysely/migration'`. Importing from `'kysely'` will provide an informative error message at compilation time. ```diff -import { Migrator, FileMigrationProvider } from 'kysely' +import { Migrator, FileMigrationProvider } from 'kysely/migration' ``` - Minimum TypeScript version is now 5.4. Versions 5.3 and older will get a very aggressive compilation error. - The library no longer ships CommonJS files. Use a Node.js version that supports `require(esm)`, or use dynamic imports. ES Modules files have moved from `/dist/esm/` to `/dist/`. - TypeScript build target was bumped to `'es2023'`. - `sql.value` and `sql.literal` were removed after spending a long time in deprecation. Use `sql.val` and `sql.lit` instead. - `db.executeQuery`'s `queryId` 2nd argument has been replaced with `options?: AbortableQueryOptions` after spending a long time in deprecation. - `QueryResult.numUpdatedOrDeletedRows` has been removed after spending a long time in deprecation. Dialects that use it need to be updated to use `QueryResult.numAffectedRows` instead. - `UniqueConstraintNode.columns` widened from `ReadonlyArray<ColumnNode>` to `ReadonlyArray<OperationNode>`. - `ExpressionBuilder.withSchema` has been removed after spending a long time in deprecation. - `DatabaseIntrospector.getMetadata` has been removed after spending a long time in deprecation. Use `DatabaseIntrospector.getTables` instead. - `MssqlDialectConfig.Tedious.resetConnectionOnRelease` has been removed after spending a long time in deprecation. Use `MssqlDialectConfig.resetConnectionsOnRelease` instead. - `MssqlDialectConfig.Tarn.options.validateConnections` has been removed after spending a long time in deprecation. Use `MssqlDialectConfig.validateConnections` instead. - `InsertQueryNode.ignore` has been removed after spending a long time in deprecation. Use `InsertQueryNode.orAction` instead. - `PrimaryConstraintNode` has been removed after spending a long time in deprecation. Use `PrimaryKeyConstraintNode` instead. - `DropTablexNodeParams` has been removed after spending a long time in deprecation. Use `DropTableNodeParams` instead. #### 🐤 New Contributors - [@&#8203;y-hsgw](https://github.com/y-hsgw) made their first contribution in [#&#8203;1496](https://github.com/kysely-org/kysely/pull/1496) - [@&#8203;williamluke4](https://github.com/williamluke4) made their first contribution in [#&#8203;1494](https://github.com/kysely-org/kysely/pull/1494) - [@&#8203;ericsodev](https://github.com/ericsodev) made their first contribution in [#&#8203;1518](https://github.com/kysely-org/kysely/pull/1518) - [@&#8203;aantia](https://github.com/aantia) made their first contribution in [#&#8203;1516](https://github.com/kysely-org/kysely/pull/1516) - [@&#8203;iam-abdul](https://github.com/iam-abdul) made their first contribution in [#&#8203;1598](https://github.com/kysely-org/kysely/pull/1598) - [@&#8203;szalonna](https://github.com/szalonna) made their first contribution in [#&#8203;1615](https://github.com/kysely-org/kysely/pull/1615) - [@&#8203;rafaelalmeidatk](https://github.com/rafaelalmeidatk) made their first contribution in [#&#8203;1338](https://github.com/kysely-org/kysely/pull/1338) - [@&#8203;jlucaso1](https://github.com/jlucaso1) made their first contribution in [#&#8203;1480](https://github.com/kysely-org/kysely/pull/1480) - [@&#8203;lucianolix](https://github.com/lucianolix) made their first contribution in [#&#8203;1363](https://github.com/kysely-org/kysely/pull/1363) - [@&#8203;shuaixr](https://github.com/shuaixr) made their first contribution in [#&#8203;1692](https://github.com/kysely-org/kysely/pull/1692) - [@&#8203;rubenferreira97](https://github.com/rubenferreira97) made their first contribution in [`ba89cc3`](https://github.com/kysely-org/kysely/commit/ba89cc338690f40d07f59a99a741b78a6a992f0d) **Full Changelog**: <https://github.com/kysely-org/kysely/compare/v0.28.17...v0.29.0> ### [`v0.28.18`](https://github.com/kysely-org/kysely/releases/tag/v0.28.18): 0.28.18 [Compare Source](https://github.com/kysely-org/kysely/compare/v0.28.17...v0.28.18) Hey 👋 A small batch of bug fixes. Please report any issues. 🤞😰🤞 This maintenance release backports bug fixes and documentation improvements from the `0.29` line. Controlled transactions get fixes for connection leaks, shared completion state, and commands racing with ongoing queries: - Commit, rollback, and savepoint commands now wait for ongoing queries and streams to finish. - Close or exhaust active streams before awaiting these commands. - A failed rollback now releases the connection and marks the transaction as rolled back. PostgreSQL and MSSQL now use session-level migration locks, including with `disableTransactions: true`. PostgreSQL migrations through PgBouncer transaction pooling need a direct connection, session pooling, or custom migration locking. #### 🚀 Features #### 🐞 Bugfixes - fix: allow explicit `undefined` in `Updateable` with `exactOptionalPropertyTypes`. by [@&#8203;y-hsgw](https://github.com/y-hsgw) in [#&#8203;1496](https://github.com/kysely-org/kysely/pull/1496) - fix infinite type check recursion by [@&#8203;koskimas](https://github.com/koskimas) in [#&#8203;1960](https://github.com/kysely-org/kysely/pull/1960) - fix: release controlled transaction connection when begin fails by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2080](https://github.com/kysely-org/kysely/pull/2080) - fix: share completion state between controlled transaction handles by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2090](https://github.com/kysely-org/kysely/pull/2090) - fix: release controlled transaction connection when rollback fails by [@&#8203;B4nan](https://github.com/B4nan) in [#&#8203;2136](https://github.com/kysely-org/kysely/pull/2136) - fix: serialize controlled transaction commands with queries by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2081](https://github.com/kysely-org/kysely/pull/2081) ##### PostgreSQL 🐘 / MSSQL 🥅 - fix: PostgreSQL and MSSQL migrations are not running exclusively when `disableTransactions: true`. by [@&#8203;morgan-coded](https://github.com/morgan-coded) & [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1919](https://github.com/kysely-org/kysely/pull/1919) ##### PostgreSQL 🐘 / SQLite 📘 - fix: allow immutable columns in `doUpdateSet`'s `where`. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2043](https://github.com/kysely-org/kysely/pull/2043) On-conflict `WHERE` predicates now use column select types, including for columns that cannot be updated. ##### PostgreSQL 🐘 - refactor(postgres): optimize table metadata parsing in `PostgresIntrospector` by [@&#8203;igalklebanov](https://github.com/igalklebanov) & [@&#8203;rubenferreira97](https://github.com/rubenferreira97) in [`ba89cc3`](https://github.com/kysely-org/kysely/commit/ba89cc338690f40d07f59a99a741b78a6a992f0d) - fix(postgres): release the client when destroyed while acquiring a connection by [@&#8203;abebelagua](https://github.com/abebelagua) & [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2088](https://github.com/kysely-org/kysely/pull/2088) ##### SQLite 📘 - fix(sqlite): output `RETURNING` before `ORDER BY` and `LIMIT` in delete queries. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;1946](https://github.com/kysely-org/kysely/pull/1946) ##### MSSQL 🥅 - fix(mssql): escape `jsonBuildObject` keys. by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2078](https://github.com/kysely-org/kysely/pull/2078) - fix(mssql): escape JSON in `jsonBuildObject` by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2079](https://github.com/kysely-org/kysely/pull/2079) #### 📖 Documentation - docs: fix PostgreSQL pool in plugin example by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2117](https://github.com/kysely-org/kysely/pull/2117) - docs: describe the `LogEvent` union by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2121](https://github.com/kysely-org/kysely/pull/2121) - docs: clarify shared pool and database instance lifecycles by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [#&#8203;2143](https://github.com/kysely-org/kysely/pull/2143) - Fix typo in `CreateTypeBuilder.asEnum` docstring by [@&#8203;anonpay-sh](https://github.com/anonpay-sh) in [`ff15048`](https://github.com/kysely-org/kysely/commit/ff15048a8f4db82b576ce93197ea7e648abfbe55) #### 📦 CICD & Tooling - ci: prepare `0.28.x` maintenance releases by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [`5e97e1d`](https://github.com/kysely-org/kysely/commit/5e97e1d7fb5e04d421d31b41948fd423d60e0ae8) - ci: publish maintenance releases under the `release-0.28` npm tag by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [`44e7c9a`](https://github.com/kysely-org/kysely/commit/44e7c9ae9bf1d4eb827d467ab82a5f62107410d6) - test: adapt earlier `0.29` regression tests to `0.28` APIs by [@&#8203;igalklebanov](https://github.com/igalklebanov) in [`7d037af`](https://github.com/kysely-org/kysely/commit/7d037afd322e4d7724af4962d999f61c94d1dd11) #### ⚠️ Breaking Changes #### 🐤 New Contributors #### What's Changed **Full Changelog**: <https://github.com/kysely-org/kysely/compare/v0.28.17...v0.28.18> </details> --- ### Configuration 📅 **Schedule**: (UTC) - Branch creation - At any time (no schedule defined) - 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. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate CLI](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0NC40LjIiLCJ1cGRhdGVkSW5WZXIiOiI0NC4xOTIuMiIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->
Update dependency kysely to ^0.29.0
Some checks failed
Build / build (pull_request) Failing after 36s
Cypress / cypress (pull_request) Failing after 21m52s
c491e1ebf0
Some checks are pending
Build / build (pull_request) Failing after 36s
Cypress / cypress (pull_request) Failing after 21m52s
Build / setup (pull_request)
Required
Build / unit (pull_request)
Required
Build / cypress (pull_request)
Required
This pull request is blocked because it's outdated.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin renovate/kysely:renovate/kysely
git switch renovate/kysely
Sign in to join this conversation.
No description provided.