Closed tayyyab closed 3 years ago
What version of the plugin are you using?
If you are not using latest version then change it to the latest, which is v0.0.5 and do a flutter clean
after that.
i have the same issus: java.lang.IllegalStateException: Expected STRING but was BEGIN_OBJECT at path $ happen when the backend send an object.
another thing, can you please add a callback by every subscribe HubMethod , cause sometimes, we need to specific thing by callback thanks so much
Although I'm little confused as why StatusChangeCallback
is raising this exception cause it was meant to be String
. I couldn't quite reproduce the issue but anyway did some changes for a possible fix. @tayyyab or @tomasgaray if any one of you can grab the latest pre-release version (0.0.6-dev.1) from the pub and test it, I'll be glad for that help.
yes I can confirm that this is working for me now. I can now receive objects.
But as tomas says, there is no way to tell which of the HubMethods triggered the hubCallback.
Thank you for the feedback and as for the hubCallBack
, I'll looking into it once I get some time.
im getting this exception when server sends a json. Its ok with receiving strings but im in trouble with jsons. Any suggestions? @AyonAB
Edit: I fixed this issue by changing in kotlin code hub.on method class type String to Object and casted received object to string.I can open pull request if its ok
I get this message on HubCallBack methods. The issue only exists in the Android.
I/flutter ( 8673): java.lang.IllegalStateException: Expected STRING but was BEGIN_OBJECT at path $
_signalRCallbackHandler Throws an exception.