Skip to content

Conversation

@derekpitt
Copy link

How do you feel about the warning message?

I don't want to even attempt to send it over the wire since we already know it will fail. But I also don't want to be silent when the message doesn't send.

Let me know!

@okjulian
Copy link
Contributor

okjulian commented Sep 9, 2018

Thanks so much for contributing with this PR! It really means a lot.

Looking at your code made me wonder if there's a more generic way to handle errors. After a bit of research about how pg-ipc handles errors, I found out that they actually emit an error event every time there's a postgres error.

This means that passing that error to the PostgresPubSub instances means that users can just subscribe to error events and get access to Postgres' errors, like "payload string too long" and more.

I opened up a PR with this new feature, which I'm sure will be very useful to you and other library users'. Would you be so kind to take a look at it? #9

PS: Sorry for closing this PR. I think the other PR is a more generic solution, but it was totally inspired by your contribution, so thanks a lot!

@okjulian okjulian closed this Sep 9, 2018
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.

2 participants