You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When working with errors returned by pq, lots of those are being generated via fmt.Errorf. This makes it hard to distinguish between different types of errors later in your own code, falling back to doing string prefix checks. So I would like to ask you to provide a separate error type which can be checked downstream.
Thanks a lot for providing this library!
The text was updated successfully, but these errors were encountered:
Some errors created within github.com/lib/pq are created with
fmt.Errorf, prefixed with "pq: ". Thus, they are not of the *pq.Error
type, but are clearly database errors.
A change request was created upstream in:
lib/pq#1169
Co-Authored-By: Alvar Penning <[email protected]>
When working with errors returned by
pq
, lots of those are being generated viafmt.Errorf
. This makes it hard to distinguish between different types of errors later in your own code, falling back to doing string prefix checks. So I would like to ask you to provide a separate error type which can be checked downstream.Thanks a lot for providing this library!
The text was updated successfully, but these errors were encountered: