Closed rajramsaroop closed 3 weeks ago
Yikes! So, adding the optional hint
parameter to DittoScopedWriteTransaction.upsert
caused bytecode incompatibility.
Can this be resolved with a gradle clean
?
clean
didn't seem to fix it.
I imagine the same would be true for DittoCollection.upsert()
as well, but I haven't tested that. And now my Android Studio is being weird and not showing me the decompiled class right now :(
@rajramsaroop @phatblat did we log something upsteam on the SDK end to dig deeper? If so, can we link it here?
@rajramsaroop @phatblat did we log something upsteam on the SDK end to dig deeper? If so, can we link it here?
No, this was the first I learned of this issue. Since this is something we've already released we can't change it now. If we revert the APIs to what they were before 4.8.0
we'd have the same type of bytecode incompatibility with the new version.
Today if you try to use Presence Degradation Reporter with a Ditto SDK >= 4.8.0 the app will crash with the following stack trace:
This is a runtime exception and occurs because the JVM couldn't find a method that matches the above method signature. A method that matches this does not match the generated java bytecode so it crashes with this exception.
The workaround for now is to explicitly add argument labels to functions so that it calls the right method. I am still investigating what work may need to be done on the SDK side to fix this.
I have isolated it to Ditto SDK 4.8.0 and above because of changes in this PR: https://github.com/getditto/ditto/pull/13336