2.0.0-preview-12
Pre-releaseToday, we are issuing the twelfth Preview release: 2.0.0-preview-12 (short: preview-12).
Breaking changes
We have adjusted the way how the Photon constructor is exported from @generated/photon, it's not a default export any more. Therefore, it now needs to be imported as follows:
import { Photon } from '@generated/photon'
// or
const { Photon } = require('@generated/photon')The previous import syntax is not valid any more:
import Photon from '@generated/photon'
// or
const Photon = require('@generated/photon')Major changes
In previous versions, when running prisma2 lift save against a database that didn't exist, Lift would always create this database on your PostgreSQL or MySQL database server without further notice.
This could lead to confusion, e.g. when there is a typo in the database name. In that case, Lift would create the database with the wrong name. preview-12 now includes an extra validation step that asks explicitly if the database should be created. You can skip the prompt using the new --create-db flag, e.g. prisma2 lift save --create-db.
Fixes and improvements per Prisma 2 repository
prisma2
- Project bootstrapped by the init flow should use the latest version of prisma2
- Migration Engine: Add
canConnectRPC