DrizzleError: Rollback is being rethrown unexpectedly
No matter which error I throw for the rollback - it doesn't work as indented because it bleeds outside the transaction as postgres-js is rethrowing it.
Such simple code results in my top-level error handler being triggered with
DrizzleError: Rollback
Relevant postgres-js line: https://github.com/porsager/postgres/blob/master/src/index.js#L271GitHub
postgres/src/index.js at master · porsager/postgres
Postgres.js - The Fastest full featured PostgreSQL client for Node.js, Deno, Bun and CloudFlare - porsager/postgres
1 Reply
This is what I'm getting from my top-level handler.
Hm, wrapping transaction inside of try/catch makes it work, but its dirty
Should I migrate this to github issues?