Comments (8)
I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.
from firebase-android-sdk.
Hi @allenjia, thank you for reaching out. I tried reproducing the issue, but I was having difficulty. Could you share an runnable MCVE that can help us investigate the issue? Aside from that, is it occurring when the app is being opened or in some other way? Are you retrieving specific data from intent extras? Thanks!
from firebase-android-sdk.
Hi @allenjia, thank you for reaching out. I tried reproducing the issue, but I was having difficulty. Could you share an runnable MCVE that can help us investigate the issue? Aside from that, is it occurring when the app is being opened or in some other way? Are you retrieving specific data from intent extras? Thanks!
It's also difficult for me to reproduce this problem. We discovered this problem from our reporting platform. Most of the crashes occurred on Android 6 and Android 7 phones. It looked like it happened when the user tried to open some pages. At this time, the user had already opened the app and Been using it for several minutes or hours.
On low-version API Android phones, we tried a method to fix this problem, which is to obtain the mExtras field in the original BaseBundle object through reflection and use it for synchronization. It seems to be effective so far. But this method is invalid for classes dynamically loaded from MeasurementDynamite.apk.
In the BaseBundle class of Android api25 and api26, the main difference is that there is no synchronization in the copy constructor in api25. When the unparce() method of the original BaseBundle object is called in the main thread, we call Intent.getExtras() in other threads. At this time, the two will process the same Parcel data, which may cause problems. So far it looks like we are not retrieving specific data from intent extras.
from firebase-android-sdk.
Thank you for additional details. Is there any chance you could share an MCVE to help us investigate the issue? That would help us check what intent data you're retrieving, as well as how the Firebase product is initialized.
Aside from that, could you updating to latest version 22.0.0 and see if the issue is resolved?
from firebase-android-sdk.
Hey @allenjia. We need more information to resolve this issue but there hasn't been an update in 5 weekdays. I'm marking the issue as stale and if there are no new updates in the next 5 days I will close it automatically.
If you have more information that will help us get to the bottom of this, just add a comment!
from firebase-android-sdk.
Thank you for additional details. Is there any chance you could share an MCVE to help us investigate the issue? That would help us check what intent data you're retrieving, as well as how the Firebase product is initialized.
Aside from that, could you updating to latest version 22.0.0 and see if the issue is resolved?
I tried many times but couldn't reproduce this problem, so I can't provide an MCVE yet. After we integrated the firebase sdk, we only called a few methods about analytics, just including setAnalyticsCollectionEnabled, setConsent and setUserId.
We will try to update to the latest version next. But most crashes belong to the second type, that is, the classes are loaded from MeasurementDynamite.apk, which is part of Google Play Services, so I think It can't be solved until the Google Play Servicesis upgraded.
As mentioned above, we have fixed the first type of problem which classes are loaded from firebase sdk by using reflection and synchronization.
public final zzcu zza(Context context, boolean z) {
try {
return zzct.asInterface(DynamiteModule.load(context, DynamiteModule.PREFER_HIGHEST_OR_LOCAL_VERSION, ModuleDescriptor.MODULE_ID).instantiate("com.google.android.gms.measurement.internal.AppMeasurementDynamiteService"));
} catch (DynamiteModule.LoadingException e) {
zza((Exception) e, true, false);
return null;
}
}
For the second type of problem which classes are loaded from MeasurementDynamite.apk, we find some other details. There is a param of "DynamiteModule.PREFER_HIGHEST_OR_LOCAL_VERSION" in com.google.android.gms.internal.measurement.zzdf.zza(). If we change it to "DynamiteModule.PREFER_LOCAL", the releated class, such as AppMeasurementDynamiteService.class, will be loaded from the firebase sdk instead of from the MeasurementDynamite.apk.
Can we fix the second type of problem by change the param from "DynamiteModule.PREFER_HIGHEST_OR_LOCAL_VERSION" to "DynamiteModule.PREFER_LOCAL"? I think this will be effective because the problem in firebase sdk has been fixed by reflection and synchronization. Will this approach cause other potential problems?
from firebase-android-sdk.
Related Issues (20)
- Firebase App Distribution 17.0.0 isn't available HOT 3
- App crash while launch HOT 5
- Crash (FirebaseApp is not initialized in this process) or ANR(executing service ***/com.onfido.android.sdk.capture.ui.OnfidoStarterService) with firebase-perf and Onfido start activity for result HOT 4
- Tasks circular dependency in `firebase-crashlytics-gradle` 3.0.0 when databinding enabled HOT 2
- java.lang.IllegalArgumentException: Service not registered HOT 2
- [firebase_crashlytics] clarify the "Proximity on" on the device status tab HOT 2
- Asking for self repository for project HOT 4
- Repeated Listen Calls observed via GCP Audio Logs HOT 7
- :app:uploadCrashlyticsMappingFileRelease build task fails after upgrading to crashlytics plugin version 3.0.1 HOT 16
- Requests from Transistor SDK are not been automatically intercepted HOT 4
- Firestore query snapshot with changes only HOT 3
- firebase-messaging build error on windows HOT 11
- Error: All gms/firebase libraries must use the exact same version specification [GradleCompatible] HOT 14
- FATAL EXCEPTION: main Process: java.lang.RuntimeException: Internal error in Cloud Firestore (25.0.0). HOT 7
- [firebase_auth] This app is not authorized to use Firebase Authentication HOT 2
- hello
- FirebaseMessaging : Disable retry Topic operation upon connection without internet HOT 2
- Android Build Error: Duplicate Class with Protobuf When Adding Firebase In-App Messaging in gradle HOT 5
- duplicate class com.google.protobuf.DescriptorProtos HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from firebase-android-sdk.