Skip to content
This repository has been archived by the owner on Dec 7, 2018. It is now read-only.

Websockets fail in Ruby 2.0.0 #31

Closed
skalee opened this issue Mar 8, 2013 · 1 comment
Closed

Websockets fail in Ruby 2.0.0 #31

skalee opened this issue Mar 8, 2013 · 1 comment

Comments

@skalee
Copy link

skalee commented Mar 8, 2013

My application sends JSONs to server via websockets. In YARV 1.9.3 it goes smooth, but in 2.0.0 there are problems when reading them from websocket. Exceptions thrown are inconsistent: either it's not valid UTF-8 or unknown opcode (various ones). From time to time it succeeds, but retrieved message is junk like "\xA9=\xEE8\xBFu\xE0 \xF2g\xF63\xB9u\xB1]". Tried with newest released version and freshly cloned repo.

WebSocket::ParserError: Payload data is not valid UTF-8
/usr/local/Cellar/ruby/2.0.0-p0/lib/ruby/gems/2.0.0/gems/websocket_parser-0.1.1/lib/websocket/parser.rb:183:in `process_message!'
/usr/local/Cellar/ruby/2.0.0-p0/lib/ruby/gems/2.0.0/gems/websocket_parser-0.1.1/lib/websocket/parser.rb:172:in `process_frame!'
/usr/local/Cellar/ruby/2.0.0-p0/lib/ruby/gems/2.0.0/gems/websocket_parser-0.1.1/lib/websocket/parser.rb:83:in `next_message'
/usr/local/Cellar/ruby/2.0.0-p0/lib/ruby/gems/2.0.0/gems/reel-0.3.0/lib/reel/websocket.rb:66:in `read'
WebSocket::ParserError: Unknown opcode 5
/usr/local/Cellar/ruby/2.0.0-p0/lib/ruby/gems/2.0.0/gems/websocket_parser-0.1.1/lib/websocket/parser.rb:216:in `opcode'
/usr/local/Cellar/ruby/2.0.0-p0/lib/ruby/gems/2.0.0/gems/websocket_parser-0.1.1/lib/websocket/parser.rb:172:in `process_frame!'
/usr/local/Cellar/ruby/2.0.0-p0/lib/ruby/gems/2.0.0/gems/websocket_parser-0.1.1/lib/websocket/parser.rb:83:in `next_message'
/usr/local/Cellar/ruby/2.0.0-p0/lib/ruby/gems/2.0.0/gems/reel-0.3.0/lib/reel/websocket.rb:66:in `read'
@skalee
Copy link
Author

skalee commented Mar 8, 2013

Sorry, I think I posted it to wrong gem :)

@skalee skalee closed this as completed Mar 8, 2013
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant