Help diagnosing this connection error: The connection to wss://s-usc1c-nss-222.firebaseio.com/.ws?v=5&ns=[my-app-id] was interrupted while the page was loading.

598 views
Skip to first unread message

David Sharek

unread,
Jan 7, 2018, 11:39:37 AM1/7/18
to Firebase Google Group

I've developed a few Web apps over the last year and have noticed the following console error on many occasions:

The connection to wss://s-usc1c-nss-222.firebaseio.com/.ws?v=5&ns=[my-app-id] was interrupted while the page was loading. WebSocketConnection.js:122

Sometimes this affects the saving of data, other times it doesn't seem to affect performance. I have not been able to detect a pattern.

This happens much more frequently during localhost testing but it also occurs on the live site.

The error displays more often on FF but I have seen it occur on Chrome as well. Oftentimes, if I leave the app for a while, I will see 10-20 of these errors in the console. No other errors are listed.

I have not seen this error reported anywhere else and so I'm having trouble diagnosing it, or even figuring out where to start.

My setup:

  • Firebase version 4.8.1 (but have seen the error on previous versions throughout the past year)
  • Blaze plan
  • Web app using: Jquery 3.1.0 / JS / HTML5 / CSS3
  • Firebase Email auth
  • Firebase Realtime Database
  • no other Firebase features
  • Hosted on https via GoDaddy

Been struggling with this for a year. I'd really appreciate some help with this. Cheers!


Frank van Puffelen

unread,
Jan 7, 2018, 11:43:16 AM1/7/18
to Firebase Google Group
Cross-posted from Stack Overflow (https://stackoverflow.com/q/48130008), but it might have a better chance at getting answered here.

Michael Lehenbauer

unread,
Jan 9, 2018, 12:09:20 AM1/9/18
to Firebase Google Group
We occasionally get reports of that error, but it is generally completely benign and can be ignored. If I remember right, it can happen if:
  • You refresh the page before Firebase's WebSocket connection has been established. The error will show up as the first message in the log, as if it happened during the fresh page load, but it's actually from the previous page load (that was canceled when you refreshed the page).

  • I'm not sure if this is still the case (I hope it's not), but Firefox used to cancel all outstanding XHR and WebSocket requests if you pressed the ESC key and this would result in the message being logged.  In that case, it does actually mean that the Firebase connection was terminated, but since the client automatically reconnects and reestablishes your state it's not a huge deal.
Hope this helps. Like I said, it's generally just a nuisance and can be ignored. But if you're experiencing connection problems, then you could capture a log (call "firebase.database.enableLogging(true)") and we could take a look.

-Michael

--
You received this message because you are subscribed to the Google Groups "Firebase Google Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebase-talk+unsubscribe@googlegroups.com.
To post to this group, send email to fireba...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/firebase-talk/af0b7f8e-af42-420d-92c5-1f2921a583ee%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages