You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am having problems with websocket disconnects on the mdbook server on Firefox. I see the following in the console:
The connection to ws://localhost:3000/__livereload was interrupted while the page was loading.
I have not been able to identify what causes this to happen. It happens very frequently, often about a minute after loading a page. However, it is quite random and there isn't an obvious cause.
This does not appear to happen on Chrome or Safari, but I have not tested those very much. I also have not had a chance to see if this happens on other systems.
This started happening within the past 3-6 months, I do not recall this being an issue in the past.
There's a variety of things to investigate:
Is this reproducible on other systems or other browsers? Is there something unique in my setup? Is it caused by some extension?
If this is unique to Firefox, is there a known issue about this?
Is there something about our Websocket implementation that is causing this?
Is this reproducible on older versions of mdbook? Was this introduced by some update?
Steps
Load a page
Wait a few minutes
Notice the websocket error, and the page will not reload when there are changes.
Possible Solution(s)
If this is a bug in Firefox, see if that has a fix?
If this is a problem in the websocket implementation, see if that can be fixed.
Perhaps look into some kind of keepalive? The websocket protocol has a native keepalive, but my understanding is that browsers don't really handle that? If not, maybe just sending a small ping message periodically could help.
Consider reconnecting if the connection is dropped? There are some potential issues with that, for example if you stop the server, and then restart it for another book. Do we want the page to reload in that scenario, or stay with the original book still open?
Notes
Firefox 137.0.2 on macOS.
Version
mdbook v0.4.48
The text was updated successfully, but these errors were encountered:
Problem
I am having problems with websocket disconnects on the mdbook server on Firefox. I see the following in the console:
I have not been able to identify what causes this to happen. It happens very frequently, often about a minute after loading a page. However, it is quite random and there isn't an obvious cause.
This does not appear to happen on Chrome or Safari, but I have not tested those very much. I also have not had a chance to see if this happens on other systems.
This started happening within the past 3-6 months, I do not recall this being an issue in the past.
There's a variety of things to investigate:
Steps
Possible Solution(s)
Notes
Firefox 137.0.2 on macOS.
Version
The text was updated successfully, but these errors were encountered: