Tuesday, 29 June 2021

Error on android device when using firebase unity sdk firestore package

I'm trying to use the firebase unity sdk in my android app. Specifically the FirebaseFirestore.unitypackage. I can get everything working running my app directly thru unity. But when I do an android build and deploy to my actual device or an emulator I get this error.

java.lang.ClassNotFoundException: Didn't find class "com/google/firebase/firestore/internal/cpp/QueryEventListener" on path: DexPathList[[zip file "/data/user/0/my.package.name/cache/firestore_resources_lib.jar"],nativeLibraryDirectories=[/vendor/lib, /system/lib]]

and then later down the log it says something similar...

E/firebase: Java class com/google/firebase/firestore/internal/cpp/QueryEventListener not found.  Please verify the AAR which contains the com/google/firebase/firestore/internal/cpp/QueryEventListener class is included in your app

I've attempted to "Build and Run" to an emulator and an actual device directly from unity. I've also attempted to export the project from unity and import it into android studio and create the apk that way, but it ends with same result.

I'm using unity 2020.3.12f1. I'm using the Android SDK Tools installed with Unity

C:\Program Files\Unity\2020.3.12f1\Editor\Data\PlaybackEngines\AndroidPlayer\SDK

I am targeting Android 9.0 API Lebel 28

I'm really not sure what is going on. I'm using another unity firebase package (the auth package) without any problems. But the second I try to use Firestore I start getting this error.

Any help would be appreciated I've been staring at this for days.

Thanks you



from Error on android device when using firebase unity sdk firestore package

No comments:

Post a Comment