libp2p / libp2p/rust-libp2p

feat(ping): make the ignoring of the first error configurable

Open
#5,004 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
5.6k
Forks
1.3k
Avg merge
8h 47m
Merged PRs (30d)
19

Description

Description

Be able to configure, the fact to ignore or not the first error of ping::Handler::poll.

Motivation

In our project, we need to rapidly detect that an error may have occurred with ping. However, like it is described here, for interoperability reasons with the Javascript libp2p, the first error is silenced. We personally don't use the Javascript implementation so we would like to be able to catch the first error.

Current Implementation

There is no need to not ignore the first error.

Are you planning to do it yourself in a pull request ?

Yes

Contributor guide

Open the contributing guide

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.

Research direction

Start at the ping::Handler::poll entry point and inspect how the first error is currently suppressed. Trace the handler configuration and existing ping behavior, then define where the opt-in choice belongs. Done means callers can choose whether to ignore the first error while retaining the current default for JavaScript libp2p interoperability.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
networking
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.