Visitar URL original
fix(knex): omit query from PostgreSQL error messages by SteveSande · Pull Request #3712 · feathersjs/feathers · GitHub
Skip to content

fix(knex): omit query from PostgreSQL error messages - #3712

Closed
SteveSande wants to merge 1 commit into
feathersjs:dovefrom
SteveSande:fix/postgres-query-in-error
Closed

SteveSande wants to merge 1 commit into
feathersjs:dovefrom
SteveSande:fix/postgres-query-in-error

Conversation

@SteveSande

Copy link
Copy Markdown

The PostgreSQL branch of the error handler stripped the SQL from the raw driver error message but the constructed errors used the raw message, so the SQL still went through. Improved the SQL parsing and actually used it for the error construction.

Fixes #3711

Perhaps the SQL is coming through for other databases. I did not test. If so, the parsing could be applied generally.

The PostgreSQL branch of the error handler stripped the SQL from the raw driver error message but the constructed errors used the raw message, so the SQL still went through. Improved the SQL parsing and actually used it for the error construction.

Fixes feathersjs#3711
@marshallswain

Copy link
Copy Markdown
Member

Thanks for this, Steve. The fix landed in #3725, which keeps your Postgres handling and tests and extends it to the other Knex drivers, compile errors, and the count and patch queries.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Postgres query leaked in error

3 participants