rust-libp2p icon indicating copy to clipboard operation
rust-libp2p copied to clipboard

Uncaught Error: closure invoked recursively or destroyed already

Open shuning-auki opened this issue 1 year ago • 0 comments

Summary

Browser throws a closure invoked recursively or destroyed already error whenever there are issues with the WebRTC connection. Can be reproduced by running browser-webrtc example.

Expected behavior

web app won't crash because of closure invoked recursively or destroyed already.

Actual behavior

Screenshot 2024-10-15 at 11 45 56

Relevant log output

2024-10-15T03:32:15.081212Z DEBUG browser_webrtc_example: Serving static file file_path=browser_webrtc_example.js
2024-10-15T03:32:15.122348Z DEBUG browser_webrtc_example: Serving static file file_path=browser_webrtc_example_bg.wasm
2024-10-15T03:32:25.410772Z DEBUG libp2p_ping::handler: Ping failure: Other { error: Custom { kind: TimedOut, error: "ping protocol negotiation timed out" } }
2024-10-15T03:32:25.410893Z  INFO libp2p_webrtc_utils::stream::drop_listener: Stream dropped without graceful close, sending Reset
2024-10-15T03:32:25.423341Z DEBUG libp2p_ping::handler: ping succeeded rtt=1.741167ms
2024-10-15T03:32:40.427055Z DEBUG libp2p_ping::handler: ping succeeded rtt=1.866791ms
2024-10-15T03:32:55.428453Z DEBUG libp2p_ping::handler: Inbound ping error: Kind(UnexpectedEof)
2024-10-15T03:32:55.428623Z DEBUG libp2p_ping::handler: Ping failure: Other { error: Custom { kind: Other, error: "Stream closed" } }
2024-10-15T03:32:55.428669Z  INFO libp2p_webrtc_utils::stream::drop_listener: Stream dropped without graceful close, sending Reset
2024-10-15T03:32:55.428716Z  INFO libp2p_webrtc_utils::stream::drop_listener: Stream dropped without graceful close, sending Reset

Possible Solution

No response

Version

8ceadaac5aec4b462463ef4082d6af577a3158b1 and master

Would you like to work on fixing this bug ?

Yes

shuning-auki avatar Oct 15 '24 03:10 shuning-auki