Transaction items run outside Postgres transaction (breaks) with random order #4331
Labels
bug/2-confirmed
Bug has been reproduced and confirmed.
kind/bug
A reported bug.
team/client
Issue for team Client.
topic: $transaction
Related to .$transaction(...) Client API
Milestone
Bug description
While using the
prisma.$transaction
feature in2.11.0
, transaction items run outside the Postgres transaction. Also the items of the JS-Array run in totally random order instead of sequential.How to reproduce
Sample code:
Result on first run:
The raw query is the last before commit, instead of the first after BEGIN.
Result on next run:
Now the raw query runs even before BEGIN, outside the Postgres transaction.
Result on any next run:
The order of the lines above appears to be totally random. Some queries even run after COMMIT.
Expected behavior
Prisma information
Environment & setup
The text was updated successfully, but these errors were encountered: