-
Notifications
You must be signed in to change notification settings - Fork 43
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
Transformable changes: crash #330
Comments
hello @jphribovsek! May i ask you what you mean by Would it be possible to get a crashlog? . Regarding sending entire objects instead of deltas, there is a way, by means of backend schemas. /cc @fredrocious Thanks! |
in SPDiffer, if you look at the call therefore the app eventually crashes: 2014-08-13 14:58:36.734 xxxxxxxxxx[57589:1303] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[NSNull length]: unrecognized selector sent to instance 0x767b068' |
if you look at
|
Note that there are two different issues here:
|
We would be interested in a way to disable diffs via schema for the base64 data we are sending. |
Hello there @danieljimenez + @jphribovsek, Please, try setting the following schema attributes, in order disable diffs:
Note: Please, bear in mind that by doing this, you would be disabling diff'ing for changes flowing from the backend to the clients. However, i'm afraid that, at least for now, the client lib doesn't handle schema options. (Which means, in other words, that any client uploading a change is likely to experience this scenario). @jphribovsek thanks for the details, much appreciated! |
Closed via #353 |
Jorge, is the server side workaround considered a fix for this issue? I was still hoping for an SDK fix; supporting the diff of base64 strings would be nice to save bandwidth |
@jphribovsek We'll be implementing the schema setting client side. At least for now, there is no support for diffing base64 strings. Thanks JP! |
We are inserting some data server side in one of our bucket. One of the bucket attributes is a transformable (bas64 string on the server).
When we modify that transformable server side, the change that is sent to the iOS client is a diff of the base64 string, similar as updating a regular string.
However, Simperium SDK attempts to apply the reverse transformer on the diff string https://github.com/Simperium/simperium-ios/blob/develop/Simperium/SPDiffer.m#L201
which gives a null value as the transformer can't decode a change string. The app eventually crashes.
Based on the SDK, it appears that in the case of base64 strings, the SDK expects to receive the entire string at every change, and not a change string.
Is there anything we can do server side to make sure the entire object is sent?
The text was updated successfully, but these errors were encountered: