-
Notifications
You must be signed in to change notification settings - Fork 183
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
Unable to use send/receive complex types that are not part of the libarary #66
Comments
Well there is a problem with the $type data in the JSON output where it includes the name of the assembly. If it can't find the specific assembly then it can't deserialize the type (or at least, reflection doesn't know what type of parameter to pass into the method and thus can't find the method or similar issues occur). All primitive types as well as guid and string receive special treatment where the assembly name is removed. If you find some better way to do it then go ahead, I bet there's a way I didn't think of at the time. All primitive types are guaranteed to work however (in JavaScript too, although I think I forgot about arrays in JS). |
Yea, that is what I finally figured out. I even added my library containing some of the complex types as a reference and it also didn't work for some reason. |
Yeah we need to look into supporting custom types properly. Sadly I can't really afford to spend a lot of time on this project. Maybe there's some code you can change to make ordinary serialization work again. I bet some of the custom Json parsing classes in Common break it at the moment and simply need some tweaking. |
well it works if I just handle the serialization of the payload... I am also running into a strange error where if I get some kind of error - not sure which one yet - and shut down my console app - then reconnect - the web app seems hung and doesn't respond to connections on the web socket layer... I haven't nailed down the exact conditions that are causing it... but I did notice the library does swallow some exceptions intentionally - so I will just have to weed through it. |
So when I try passing a complex type into or recieving one back from the library - I get json serialization errors... So basically, if I am wanting to send a list of type user - I have to serialize before sending and deserialize on the other end with known types - is this by design?
The text was updated successfully, but these errors were encountered: