Skip to content

Conversation

@lidel
Copy link
Member

@lidel lidel commented Nov 11, 2025

Problem

go-libp2p 0.44 and 0.45 log operational webrtc noise ad loud ERRORs

This impacts projects like kubo, which run webrtc-direct listener by default:

Analysis

Pre-v0.44 (Working State)

PR #2915 by @sukunrt deliberately downgraded all pion logs to Debug level because "Pion logs are too noisy and have invalid log levels". This worked correctly for ~1 year without issues.

v0.44.0 (Regression)

PR #3364 by @MarcoPolo migrated from go-log/v2 to log/slog but accidentally reverted the pion log level downgrade. The migration kept the comment claiming logs were downgraded but changed the implementation to log Error/Warn/Info at their face values, causing routine connection events to spam error logs.

Solution

Similar to PR #3413 which fixed this issue for websocket transport, WebRTC transport needs the same treatment. Pion logs client disconnects, protocol mismatches, and state races as ERROR/WARN, but these are normal operational noise from a service perspective, not actual errors requiring operator attention.

This restores PR #2915 behavior: downgrade all pion logs to Debug level.
Users who need to debug WebRTC issues can still use that level.

Fixes ipfs/kubo#11053

Pre-v0.44 (Working State):
PR #2915 deliberately downgraded all pion logs to Debug level because
"Pion logs are too noisy and have invalid log levels". This worked
correctly for ~1 year without issues.

v0.44.0 (Regression):
PR #3364 migrated from go-log/v2 to log/slog but accidentally reverted
the pion log level downgrade. The migration kept the comment claiming
logs were downgraded but changed the implementation to log Error/Warn/Info
at their face values, causing routine connection events to spam error logs.

Similar to PR #3413 which fixed this issue for websocket transport,
WebRTC transport needs the same treatment. Pion logs client disconnects,
protocol mismatches, and state races as ERROR/WARN, but these are normal
operational noise from a service perspective, not actual errors requiring
operator attention.

This restores PR #2915 behavior: downgrade all pion logs to Debug level.

Fixes ipfs/kubo#11053
@MarcoPolo MarcoPolo merged commit 5d5f8d7 into master Nov 11, 2025
10 of 12 checks passed
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.

ERROR from webrtc-transport-pion Failed to accept data channel

3 participants