Skip to content

Commit

Permalink
panic hook for bad request begin transaction
Browse files Browse the repository at this point in the history
  • Loading branch information
asmyasnikov committed Jan 26, 2025
1 parent 9f46a6e commit ba839f5
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions internal/query/session.go
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,10 @@ func (s *Session) Begin(
if err != nil {
s.setStatusFromError(err)

if xerrors.IsOperationError(err, Ydb.StatusIds_BAD_REQUEST) {
panic(err)
}

return nil, xerrors.WithStackTrace(err)
}

Expand Down

0 comments on commit ba839f5

Please sign in to comment.