Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Websocket error on Atmosphere.js #1146

Closed
confile opened this issue Jun 17, 2013 · 7 comments
Closed

Websocket error on Atmosphere.js #1146

confile opened this issue Jun 17, 2013 · 7 comments

Comments

@confile
Copy link

confile commented Jun 17, 2013

When using websocket I get the following console errors:

Uncaught TypeError: Cannot call method 'toString' of undefined atmosphere.js:2572
atmosphere.util.trim atmosphere.js:2572
_handleProtocol atmosphere.js:1254
_trackMessageSize atmosphere.js:1297
_executeWebSocket._websocket.onmessage
@jfarcand
Copy link
Member

Not sure which sample you are using, but everything works as expected for me using the samples/chat . Can you share a test case? Also which version are you using? Which browser? Thanks!

@confile
Copy link
Author

confile commented Jun 17, 2013

I use the GWT20 JSON sample. I have no testcase. Longpolling works fine.

I use the latest version of atmosphere.js and atmosphere core RC4 and atmosphere GWT RC3.

Since the code is running fine on all other transports the error must be in atmosphere.js

@jfarcand
Copy link
Member

Which browser?

@confile
Copy link
Author

confile commented Jun 17, 2013

Chrome latest version. MAC OSX latest version

@confile
Copy link
Author

confile commented Jun 17, 2013

same error in Mac Firefox 21

@confile
Copy link
Author

confile commented Jun 17, 2013

It turns out that this error happens to the first message being sent with websocket

Uncaught TypeError: Cannot call method 'toString' of undefined atmosphere.js:2572
Tue Jun 18 01:20:34 CEST 2013 buddyis.client.Test
INFO: JSON Connection opened
Tue Jun 18 01:20:34 CEST 2013 buddyis.client.Test
INFO:
Tue Jun 18 01:20:34 CEST 2013 org.atmosphere.gwt20.client.AutoBeanClientSerializer
INFO: Deserialize {"data":"dsfdsfdfgdfg"} from {"data":"dsfdsfdfgdfg"}
Tue Jun 18 01:20:34 CEST 2013 buddyis.client.Test
INFO: received message through JSON: dsfdsfdfgdfg

@jfarcand
Copy link
Member

jfarcand commented Aug 6, 2013

Unable to reproduce

@jfarcand jfarcand closed this as completed Aug 6, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants