Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error Handling on Reconnect #225

Closed
JessyCat92 opened this issue May 12, 2017 · 2 comments
Closed

Error Handling on Reconnect #225

JessyCat92 opened this issue May 12, 2017 · 2 comments

Comments

@JessyCat92
Copy link

Actual behaviour:
If you connect to a channel you can handle connection error with the promise handling .catch()
But if you set reconnect = true then this will only work for first try of connection.
For reconnects there is no error handling. So it results in "(node:20312) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 18): Unable to connect."
The reson is simply, that tmi.js has no error handling here (it calls simply this.connect() with out catching the error from returned promise)

Expected behaviour:
There should be any kind of error handling. Maybe via eventhandler "error" or maybe a new "reconnect error"

Error log:
"(node:20312) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 18): Unable to connect."

Server configuration

  • Operating system: Windows
  • Node version (if applicable): 6.10.2
  • NPM version (if applicable): 3.10.10
  • tmi.js version: 1.2.0
@Schmoopiie
Copy link
Member

tmi.js is only supported by Node 4.x at this time. There is no ETA when we will support Node 6.x and 7.x

@Schmoopiie
Copy link
Member

Closing this as it is a duplicate of #201

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

No branches or pull requests

2 participants