12

Resolved

Could not deserialize data returned from server

description

If you should happen to see this error when calling Users.GetInfo() it's because facebook changed something in the way their hs_info is passed down and the C# API is not expecting nullable values.
 
Here is the fix:
 
recompile the binaries from source with the following members and their referencing properties set to set to int?
 
These are members of > Facebook.Schema.hs_info
 
private int? grad_yearField;
private int? hs1_idField;
private int? hs2_idField;
 
If you don't have the capability or need to get your site running ASAP.. i've attached the binaries with this change already compiled in.
 
~Lucas Smolic

file attachments

comments

mwawrusch wrote Mar 31, 2010 at 7:53 AM

Thank you for providing this quick fix. At this point I think Clarity Consulting should really considering either modifying the xml parsing process to handle such errors seamlessly or switch to a different deserialization logic. It is just not acceptable that such minor changes from Facebook kill production systems. Microsoft, Facebook and Clarity committed themselves to this toolkit. It's time to step up for them and get their act together.

ravipulluri wrote Mar 31, 2010 at 8:01 AM

thxs very much........

wrote Mar 31, 2010 at 8:01 AM

wrote Mar 31, 2010 at 8:51 AM

mbuferli wrote Mar 31, 2010 at 9:32 AM

Hi, with this new temp dll, IFrameCanvasMaster don't work.
Canvas around the IFrame does not render.

wrote Mar 31, 2010 at 11:03 AM

fde001 wrote Mar 31, 2010 at 11:12 AM

Thank you for the solution.

Qandil wrote Mar 31, 2010 at 11:20 AM

Here is a quick fix for the latest build, before replace please take a backup

or just download and replace the "hs_info" class

wrote Mar 31, 2010 at 11:20 AM

Qandil wrote Mar 31, 2010 at 11:20 AM

the posted file is * Xsd2CodeSource.cs

regards,

mbuferli wrote Mar 31, 2010 at 11:29 AM

Qandil, that source fix all problem? IframeMaster rendering too?

Qandil wrote Mar 31, 2010 at 12:39 PM

Nope i didnt check that, my fix if only maps the Users.GetInfo() exception

sintetico82 wrote Mar 31, 2010 at 12:42 PM

Thanks.

wrote Mar 31, 2010 at 12:48 PM

amnigos wrote Mar 31, 2010 at 12:50 PM

This is really annoying, a small change has brought our entire production system down.

I agree with @mwawrusch comment, Microsoft should show real commitment & fix this kind of trivial things from happening in the future.

wrote Mar 31, 2010 at 1:12 PM

Crypth wrote Mar 31, 2010 at 1:26 PM

wrote Mar 31, 2010 at 2:18 PM

wrote Mar 31, 2010 at 3:25 PM

DealieDo wrote Mar 31, 2010 at 3:41 PM

What a mess. Just when we start to garner users, this happens. This is poor and pathetic. I tried using the new binaries, but I cannot compile. Ahhhh this is really painful.

DealieDo wrote Mar 31, 2010 at 3:56 PM

Thank you Mr. Smolic for the assistance. I was to panicked with the outtage, that I made a deletion that prevented my site from compiling. All is well thanks to these new binaries you posted. That just took years off my life! What the darn heck is Facebook doing?

wrote Mar 31, 2010 at 4:16 PM

wrote Mar 31, 2010 at 4:39 PM

wrote Mar 31, 2010 at 4:42 PM

edhalsim wrote Mar 31, 2010 at 5:36 PM

mbuferli: I'm having the same problem. My IFrameCanvasMaster app. no longer works. The canvas doesn't render and I'm unable to authenticate the auth_token using api.Auth.GetSession( authToken ). Does anyone have a fix?

OTamayo wrote Mar 31, 2010 at 5:37 PM

Thanks so much; I thought I had messed up my code :-)

wrote Mar 31, 2010 at 6:03 PM

jimzim wrote Mar 31, 2010 at 6:08 PM

Thanks Lucas Smolic for pointing this out specifically. I just found your code and will update the source according to what you put up here. I am thinking that Facebook is going to change this again, so we need to find a better solution than patch and update all facebook apps. :) Our company uses this for too many critical apps.

jimzim wrote Mar 31, 2010 at 6:30 PM

Updated source tree to 48896 Thanks Lucas! We need to a better way to parse the xml.

wrote Mar 31, 2010 at 7:18 PM

rahuljos wrote Mar 31, 2010 at 10:19 PM

Hi, is it possible to get the updated binary of Facebook.Silverlight.dll with the current fix? I'm probably missing something obvious but the main build fails to compile due to missing assembly references.

Thanks.

juliansuggate wrote Mar 31, 2010 at 10:19 PM

Thanks for providing such a speedy fix. If this project was truly community-driven however, we wouldn't have to wait around for one of the admins to do this sort of thing. I spent half a day yesterday trying to fix this myself after it brought down our production system. Below are my experiences, which may indicate why this project is stagnating.

Not having delved into the toolkit before, I thought perhaps the classes needed regenerating from XSD. So I tried that. I must say, the process of hand-editing the facebook XSD and then also hand-editing the generated CS classes was horrifying. Why on Earth do I need to make such mechanical changes myself? Can't this project use a modified version of xsd2Code that incorporates more finegrained awareness of the Facebook XSD?

Worse, I found that the generated code doesn't compile -- even after making the aforementioned changes. The RestBase hierarchy is out-of-date with the types defined in the XSD, for example, it appears that Facebook have normalised the action_links type into stream_publishAction_links and template_bundleAction_links.

I have to agree with @mwawrusch.

rahuljos wrote Mar 31, 2010 at 10:50 PM

Hi, can you also host an updated version of Facebook.Silverlight.dll? My attempts to compile the MAIN build code fails with several errors.

Thanks.

peter78 wrote Apr 1, 2010 at 3:57 PM

What about the silverlight dll , i cant compile it what should i do? please help me !

jimzim wrote Apr 1, 2010 at 4:00 PM

The silverlight fix should be up shortly. Ryan said he is going to check in a silverlight solution that builds without the dashboard stuff which is currently breaking in Silverlight solution.

jimzim wrote Apr 1, 2010 at 4:10 PM

Ryan just checked in a silverlight solution that compiles with the new api changes. Changeset 48944

peter78 wrote Apr 1, 2010 at 4:55 PM

thank you, the silverlight is working now

RobertMGlynn wrote Apr 1, 2010 at 8:55 PM

Thank you Lucas. You've just saved me (and I imaging a whole lot of other people) a bunch of time.

wrote Feb 22, 2013 at 12:37 AM

wrote May 16, 2013 at 12:10 PM

wrote May 16, 2013 at 12:10 PM

wrote Jun 14, 2013 at 8:27 AM