Closed aurimasc closed 2 years ago
I see there's branch confilcts in: com.unity.mobile.notifications/Runtime/Android/Plugins/com/unity/androidnotifications/UnityNotificationManager.java
I've encountered an issue on OS: 5.0.1 device (Samsung Galaxy S4, ) and 5.0.2 ( HTC One M9+), where application crashes on launch
I do not have 5.1 device, therefore not sure if it's affected, but I think this should be addressed.
05/19 05:10:36.912 9203 9281 Debug UnityNotifications Checking for invalid notification IDs still hanging around 05/19 05:10:36.913 9203 9281 Error AndroidRuntime FATAL EXCEPTION: Thread-286 05/19 05:10:36.913 9203 9281 Error AndroidRuntime Process: com.unity3d.mobilenotificationtests, PID: 9203 05/19 05:10:36.913 9203 9281 Error AndroidRuntime java.lang.Error: FATAL EXCEPTION [Thread-286] 05/19 05:10:36.913 9203 9281 Error AndroidRuntime Unity version : 2020.3.34f1 05/19 05:10:36.913 9203 9281 Error AndroidRuntime Device model : HTC HTC_M9pw 05/19 05:10:36.913 9203 9281 Error AndroidRuntime Device fingerprint: htc/hiau_ml_tuhl_htc_asia_tw/htc_hiau_ml_tuhl:5.0.2/LRX22G/670935.3:user/release-keys 05/19 05:10:36.913 9203 9281 Error AndroidRuntime Build Type : Development 05/19 05:10:36.913 9203 9281 Error AndroidRuntime Scripting Backend : Mono 05/19 05:10:36.913 9203 9281 Error AndroidRuntime ABI : armeabi-v7a 05/19 05:10:36.913 9203 9281 Error AndroidRuntime Strip Engine Code : false 05/19 05:10:36.913 9203 9281 Error AndroidRuntime 05/19 05:10:36.913 9203 9281 Error AndroidRuntime Caused by: java.lang.NoSuchMethodError: No virtual method getActiveNotifications()[Landroid/service/notification/StatusBarNotification; in class Landroid/app/NotificationManager; or its super classes (declaration of 'android.app.NotificationManager' appears in /system/framework/framework.jar) 05/19 05:10:36.913 9203 9281 Error AndroidRuntime at com.unity.androidnotifications.UnityNotificationManager.findInvalidNotificationIds(UnityNotificationManager.java:434) 05/19 05:10:36.913 9203 9281 Error AndroidRuntime at com.unity.androidnotifications.UnityNotificationManager.performNotificationHousekeeping(UnityNotificationManager.java:407) 05/19 05:10:36.913 9203 9281 Error AndroidRuntime at com.unity.androidnotifications.UnityNotificationManager.lambda$triggerHousekeeping$0(UnityNotificationManager.java:391) 05/19 05:10:36.913 9203 9281 Error AndroidRuntime at com.unity.androidnotifications.-$$Lambda$UnityNotificationManager$fSttc7CuZmP-kDH-q_FquZSJ7Yk.run(lambda) 05/19 05:10:36.913 9203 9281 Error AndroidRuntime at java.lang.Thread.run(Thread.java:818)
Tested on devices: • VLNQA00011 - Xiaomi Mi 5s (MI 5s), CPU: Snapdragon 820 MSM8996, GPU: Adreno 530, OS: 6.0.1 • VLNQA00140 - Samsung Galaxy S4 (GT-I9505), CPU: Snapdragon S4 Plus MSM8960, GPU: Adreno 320, OS: 5.0.1 • VLNQA00057 - HTC One M9+ (HTC_M9pw), CPU: MediaTek Helio X10 MT6795T, GPU: PowerVR Rogue G6200, OS: 5.0.2
A new feature proposed by innogames: ability to make notification only show up when app is in background (iOS already had this feature, so this brings more parity).
After this change:
Test coverage:
Guidelines for testing: