denoland / denoland/fastwebsockets

Split set_auto_ping, set_auto_close issue

Open
#87 6 comments 1 reaction 0 assignees View on GitHub
Dominant language
Rust
Stars
1.1k
Forks
112
PR merge metrics
No merged PRs in 30d

Description

Splitted channels require explicitly set set_auto_ping, set_auto_close to false, otherwise frames are being captured without write, which creates wrong frames in reader channel, i.e. instead of OpCode::Ping, reader reads OpCode::Pong on server Ping.

```rust
let (mut ws, _) =
fastwebsockets::handshake::client(&SpawnExecutor, req, tls_stream).await?;
ws.set_auto_pong(false);
ws.set_auto_close(false);
let (rx, tx) = ws.split(tokio::io::split);
let rx = FragmentCollectorRead::new(rx);
Ok((rx, tx))
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.