node-pg-error icon indicating copy to clipboard operation
node-pg-error copied to clipboard

node-postgres now uses an error subclass

Open cakoose opened this issue 4 years ago • 0 comments

The latest version of node-postgres (NPM package "pg") uses a subclass of Error called DatabaseError.

  1. I think it was added around Dec 2019: commit.
  2. It was exported from 'pg-protocol' in Oct 2020: changelog entry.

Also, pg-error's instructions to modify connection.parseE and connection.parseN doesn't seem to work in the latest version of node-postgres.

Suggestion: Update pg-error's ReadMe to tell people that they can just use DatabaseError now. Would have saved me a bunch of time debugging.

cakoose avatar Jan 17 '21 21:01 cakoose