-
Notifications
You must be signed in to change notification settings - Fork 338
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
Unhandled rejection when connection to eventsource gets terminated #224
Comments
Is there an answer to that question now? |
Bump |
You are saying it is "connection termination", but really the line of code of XMLHttpRequest.js looks like something else. Is it a bug of that lib? The attached stack trace does look relevant to EventSorce library. Is the exception really not caught? |
I am not sure what is happening in my case but even with a proper internet connection, the request throws this exception with the error message of "TypeError: terminated" with the cause always as If there is anything I can do to get clearer error messages or more info, please do suggest them. |
I am using the event-source-polyfill library to create an EventSource connection in my Nodejs project using the dynamic imports mentioned in docs.
The connection to the eventsource server gets terminated occasionally due to unknown reasons.
Expected behaviour:
Eventsource catches the error caused by connection termination and handles it as required
Actual behaviour:
The error thrown due to this termination is not caught, leading to an
unhandlerejection
in the node process. The error stack I obtain is:Additional details
The EventSource is initialized by:
The error is thrown from time-to-time when the eventsource times out and creates a new connection.
The text was updated successfully, but these errors were encountered: