medz / prisma-dart

Prisma Client Dart is an auto-generated type-safe ORM. It uses Prisma Engine as the data access layer and is as consistent as possible with the Prisma Client JS/TS APIs.
https://prisma.pub
BSD 3-Clause "New" or "Revised" License
459 stars 31 forks source link

v5.0.2 prisma-query-engine is copied to the generation folder. #399

Closed pro100andrey closed 5 months ago

pro100andrey commented 5 months ago
Screenshot 2024-06-09 at 14 41 25

Example project example.zip

Steps to reproduce:

  1. dart pub get

  2. npm i --save-dev prisma@latest

  3. npx prisma generate

  4. dart compile exe bin/example.dart -o bin/example

  5. ./bin/example

After running the example, I receive the following exception.

Unhandled exception:
PrismaClientInitializationError: QE404 No binary engine found, please make sure any of the following locations contain the executable file: {prisma-query-engine, prisma/prisma-query-engine, .dart_tool/prisma-query-engine}

As far as I understand, this is incorrect behavior, right?

I may be mistaken, but it seems that prisma-query-engine should indeed be copied to the root of the project during generation, as shown in the example below:

Screenshot 2024-06-09 at 14 55 58
pro100andrey commented 5 months ago

While I was creating the issue, you already fixed it. :)

fixed in 5.0.3