obsproject / obs-websocket

Remote-control of OBS Studio through WebSocket
GNU General Public License v2.0
3.8k stars 701 forks source link

Bug: Document description error #1137

Closed button-chen closed 6 months ago

button-chen commented 1 year ago

Operating System Info

Windows 11

Other OS

No response

OBS Studio Version

29.0.x

OBS Studio Version (Other)

No response

obs-websocket Version

5.1.0

OBS Studio Log URL

https://github.com/obsproject/obs-websocket/blob/master/docs/generated/protocol.md

OBS Studio Crash Log URL

No response

Expected Behavior

If a text frame is received when using the obswebsocket.json (default) subprotocol, or a binary frame is received while using the obswebsocket.msgpack subprotocol, the connection is closed with WebSocketCloseCode::MessageDecodeError.

Current Behavior

If a binary frame is received when using the obswebsocket.json (default) subprotocol, or a text frame is received while using the obswebsocket.msgpack subprotocol, the connection is closed with WebSocketCloseCode::MessageDecodeError.

Steps to Reproduce

  1. Incorrect document description in bold font

Anything else we should know?

No response

tt2468 commented 6 months ago

No such text exists in the current protocol documentation. The documentation does state this:

If a binary frame is received when using the obswebsocket.json (default) subprotocol, or a text frame is received while using the obswebsocket.msgpack subprotocol, the connection is closed with WebSocketCloseCode::MessageDecodeError

This statement is correct. JSON is a text format, msgpack is a binary format.