Forum Multiplayer Error: null in callback handler for Connection (Generic)

Discussion and help relating to the PlayerIO Multiplayer API.

Error: null in callback handler for Connection (Generic)

Postby UnknownGuardian » June 23rd, 2010, 5:10 am

A really odd connection issue I have been getting a lot lately. The error shows up in my admin panel as

null in callback handler for Connection (Generic)

I never get a debug showing up, but luckily once I caught the error, and printed it to a textfield from my game. It said something about a security error on it. The only other person that I have encountered that is getting the error, which I believe, he makes up for 95% of the errors I have received of that type over the last few days, says he has a high ping and has to refresh the game a lot just to get it to log in. Can't tell if its his game reporting the errors or not. Are the three things related? The null callback handler, the security error and the high ping causing connection failures?

And what should I do about these errors? Should I attempt to reestablish a server connection, and if I did, does that leave me with 2 connections to the server, thus exceeding my package limitation, and does the null connection exist even?

Thanks ahead of time,
UG
UnknownGuardian
 
Posts: 94
Joined: May 25th, 2010, 5:11 am

Re: Error: null in callback handler for Connection (Generic)

Postby Benjaminsen » July 2nd, 2010, 9:51 am

Hi UG

The specific error just means that the user was unable to connect to the multiplayer server. The null you see in error log is simply an empty stack-trace.

I did some changes to the API yesterday that should give better error messages from now on forward. The update is automatic and you don't have to download anything.
Benjaminsen
.IO
 
Posts: 1444
Joined: January 12th, 2010, 11:54 am
Location: Denmark

Re: Error: null in callback handler for Connection (Generic)

Postby UnknownGuardian » July 2nd, 2010, 6:40 pm

Good news is that I added a ton of try and catch blocks as well as checking if null stuff in it, and since then, it looks like I haven't seen the problem at all.

I wrapped the connect method and any room joining code in try catches, as well as checked if the client and connection were null before proceeding. It seems to have helped.
UnknownGuardian
 
Posts: 94
Joined: May 25th, 2010, 5:11 am


Return to Multiplayer