We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
_handleError
ECONNREFUSED
As per vitalets/websocket-as-promised#47 we discovered there's a bug in reconnecting-websocket as well as @opensumi/reconnecting-websocket:
reconnecting-websocket
@opensumi/reconnecting-websocket
https://github.com/opensumi/reconnecting-websocket/blob/6010e6b99967c2977c7abc7d0a1845245c101eb2/reconnecting-websocket.ts#L478-L489
Needs changed to:
private _handleError = (event: Events.ErrorEvent) => { this._debug('error event', event.message); - this._disconnect(undefined, event.message === 'TIMEOUT' ? 'timeout' : undefined); + this._disconnect(undefined, event.message === 'TIMEOUT' ? 'timeout' : event.message); if (this.onerror) { this.onerror(event); } this._debug('exec error listeners'); this._listeners.error.forEach(listener => this._callEventListener(event, listener)); this._connect(); };
Otherwise the err.reason will be undefined and not bubble up to the error listener, and you won't have a clue as to what happened.
err.reason
cc @bytemain
The text was updated successfully, but these errors were encountered:
open()
No branches or pull requests
As per vitalets/websocket-as-promised#47 we discovered there's a bug in
reconnecting-websocket
as well as@opensumi/reconnecting-websocket
:https://github.com/opensumi/reconnecting-websocket/blob/6010e6b99967c2977c7abc7d0a1845245c101eb2/reconnecting-websocket.ts#L478-L489
Needs changed to:
Otherwise the
err.reason
will be undefined and not bubble up to the error listener, and you won't have a clue as to what happened.cc @bytemain
The text was updated successfully, but these errors were encountered: