Closed vkrot closed 5 years ago
Thanks for submitting the issue!
The library should handle parsing errors better than it does. The original intent was that we wanted hard failures so we could easily catch problems. A better solution is to catch these exceptions and emit an error
event.
This pushes error handling onto the consumer of the library. If the consumer wants to ignore / log errors they attach an error
event handler. The default behavior when no error
handler exists will terminate the application as it does now.
I see, thanks a lot for quick response. I never used js before, so didn't know that.
No problem. Reopening the issue. Sorry I was unclear with my previous message and was just thinking out loud.
At present, CCXWS clients do not emit the error
event. At current, it will always result in a hard failure.
We still need to add this functionality into the library.
Addressed in PR #95
Exchange Upbit
Subscription type Trades
Describe the bug Error parsing upbit json response, process exited on error. This happened after a few successful days of consuming upbit trades socket. I think node process should not stop on such kinds of errors?
To Reproduce Steps to reproduce the behavior: No idea, this fixed after restart and happened only once.
Expected behavior Log error, but do not stop proccess