[AIO] No client side ping-pong

Open
#187 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
38/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
python
Domain
networking

Research direction

Start by reviewing the AIO client context described in the issue and the referenced Protocol implementation at heisenbridge/irc.py#L12. Determine where client-side keepalive behavior belongs and how it should detect an idle or stalled socket. Done means the AIO client sends periodic pings and detects an unresponsive server without waiting for an application send.

Written by the indexing model from the issue text.

Description

IRC servers PING clients if the TCP connection is idle to ensure dead streams are dropped. On the other hand clients need to do the same to detect the same issue if they don't get anything from servers for a good while.

Currently no client side ping is implemented and if the socket stalls it will only be detected by the TCP stack when you try to send something and you immediately get disconnected. This is not ideal when you want to stay connected.

I have a local implementation for the AIO client currently implemented as a Protocol: https://github.com/hifi/heisenbridge/blob/master/heisenbridge/irc.py#L12

Let me know if this can be worked upstream somehow. It has been field tested by now that it seems to do about the right thing.

Dominant language
Python
Stars
422
Forks
91
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from jaraco/irc

All issues in jaraco/irc

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.