Skip to content

fix: wait for forwarding mesh before publishing - #3

Closed
peerbit-org wants to merge 1 commit into
libp2p:mainfrom
peerbit-org:peerbit-org/pubsub-mesh-readiness-20260912
Closed

peerbit-org wants to merge 1 commit into
libp2p:mainfrom
peerbit-org:peerbit-org/pubsub-mesh-readiness-20260912

Conversation

@peerbit-org

@peerbit-org peerbit-org commented Sep 12, 2026 •

Copy link
Copy Markdown

Wait for the required Gossipsub mesh peers before publishing. Subscription announcements alone do not guarantee that the intermediate peer can forward messages.

Use getMeshPeers in the existing readiness poll and assert that every accepted fruit reaches node 3. Keep the rejected-fruit assertion.

Validation: delaying the first heartbeat by one second reproduces a missing second hop and timeout on the original source. Both example tests pass with the fix, with and without that diagnostic delay.

No dependency, timeout, retry, or transport changes.

@tabcat

tabcat commented Oct 8, 2026

Copy link
Copy Markdown
Member

Thanks for this! The same fix (waiting for the gossipsub mesh before publishing) landed via the examples monorepo in libp2p/js-libp2p-examples#347 and is now synced here, so I'm closing this as superseded.

@tabcat tabcat closed this Oct 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants