buttplug
buttplug copied to clipboard
JSON parser doesn't handle streamed JSON
Describe the bug
- Open a legacy C# program like ScriptPlayer, connect to Intiface CLI somehow
- Connect 3 or more toys
- Start a video, all toys should move
- Hit stop
Expected behavior All toys stop
Actual behavior Any non-linear toy may not stop, JsonSerializerError message about "trailing characters" posted.
Additional context C# packs StopAllDevices into a series of StopDeviceCmd messages, each with their own array, then ships them all at once in the same Websocket packet. This chokes the parser, which isn't set up to handle streaming correctly.