-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Automatically reconnect on offline event #9299
Automatically reconnect on offline event #9299
Conversation
b3b8ac9
to
b6e0709
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code LGTM. Although I wasn't able to reproduce the issue on master using Linux and Chrome. It is working for me with and without this change.
I was unable to reproduce the issue as well on both master and this pull-request. |
@Darkgaja can you confirm that you have the issue as of master and that this PR fixes it for you? I don't see any regression, so if it fixes it for you then I'll merge. |
@marechal-p @vince-fugnitto Just tested it on the master and the issue still persists: 2021-04-13_08-46-40.mp4(Saving doesn't work, git synchronisation as well. Waiting doesn't help) My changes seem to fix these issues: 2021-04-13_11-15-32.mp4 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Darkgaja thank you for providing the screenshares, they helped me reproduce the issue on master and I confirmed that the pull-request addresses the issue nicely 👍
What it does
Fixes #9298.
As the bug report over at chromium indicates, listening to the
offline
event of the browser enables us to manually tell the socket to reconnect. This event is usually fired during a change of network.I tested this behavior on an Ubuntu 20.04 machine. Running a VM on Windows 10 didn't allow me to reproduce the network issue. I also looked for any regression issues under Firefox and Windows, but everything seems to work normally even with the fix in place.
How to test
Review checklist
Reminder for reviewers