-
Notifications
You must be signed in to change notification settings - Fork 49
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
Gracefuly check connection status with server PINGs #124
Conversation
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.
Looks like you targeted the master branch with these changes, I would prefer you to target develop
.
I have changed the pull request's target branch, but could you please rebase your commit against upstream/develop?
master
is reserved for releases, whereas develop
is used as the destination for pull requests for the next release.
As for the content of the changes, they look mostly good to me, short one or two minor things.
The MR looks otherwise good to me! Thanks a lot for doing this work, and participating in the discussion upfront about it. |
I apologize for that. I believe there's a way to select a default PR branch in github for that purpose. |
Good call, I've changed this in the project settings now. This wasn't done before as I believe @theunkn0wn1 has no access to those settings, and moving the main development HEAD to |
Co-Authored-By: Joshua Salzedo <thHunkn0WNd@gmail.com>
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.
LGTM 👍
Please note I have changed |
Yes I had noticed that, Upon consideration we should keep the old name, or alias it with a property. Otherwise it will take a major point release to merge this. |
I did notice that -- I was going to propose to add a property that proxies to Unrelatedly, I think the current reconnect code is a bit flaky as well; once that has been fixed, it seems the connection problems would finally be gone for good. |
I was going to touch the reconnect code soon anyways, as i intend to work in #117 over the weekend. My current idea will require changing how pydle expects a disconnect. |
Just so we're on the same page, is there anything you'd like me to do? should I add the proxy property or defer to a later PR? I would love to see this merged and ideally released because right now I am using this library with a modified Personally I don't think this is a huge breaking change because if someone DID modify Let me know how you'd like to proceed. |
Since this resolves an immediate issue here is what I think is best: I am drafting this fix up shortly, so we can do a point release soon. If anyone is both dependent on modifying the renamed variable and is using the develop branch, they should be aware of the risk to using a development branch rather than a release branch. |
Currently, every 5 minutes of no data received, the connection will terminate, assuming the server is dead or another issue has occurred. Some servers, such as irc.mzima.net have a higher default PING timeout than 5 minutes, causing false-positives of dead-sockets.
This PR changes this behaviour to instead, PING the server to check if it's still there - when we don't hear back, we THEN terminate the connection.
Fixes #51