Meteor-Community-Packages / Meteor-Community-Packages/raix-push

Android 7.1 crashes after receiving a notification

Open
#304 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
505
Forks
191
PR merge metrics
No merged PRs in 30d

Description

Hello @raix, I am running into this for a moment now, I have this in the server logs:

```
Create GCM Sender using "AAAAzbVo4wU:APA91bHKgK-hBATPUB69y-PO16qprQYapDLIOpXiOYPJ5PMbRtGmVct5IwwIECJ-tojxBpu-S-8WGtj9UYejir9NbV5WXyHwkWlxn7QZJVyYD6Xdal6PQiZdGMUDo3NRIZZBEGvrHhkC"

A:Send message to: dhK3NA7uBz0:APA91bHWpPErDoe9lBIyBIeyCK01PdBZZCZBVCcikk_ff3OCyrVx-Q-3rdZqWCHf1Is7eXK7eSD1mAKRlruTrvROJXrp-gs2jEaYzcVS0icnxww5WD50_F5FczU7HmSH_M6_fy1hw6rJ

Push: Sent message "test" to 0 ios apps 1 android apps
ANDROID: Result of sender: {"multicast_id":4944916987780141000,"success":1,"failure":0,"canonical_ids":0,"results":[{"message_id":"0:1495236093744598%636bc0890022d8ce"}]}
```
Which means everything seems to be working correctly.

But my One Plus 3, running on Android 7.1.1, instantly crashes, saying Unfortunately System UI has stopped.

When I look into the android logs, I see :
```
05-20 00:00:39.498 14499 14499 D AndroidRuntime: Shutting down VM
05-20 00:00:39.499 14499 14499 E AndroidRuntime: FATAL EXCEPTION: main
05-20 00:00:39.499 14499 14499 E AndroidRuntime: Process: com.android.systemui, PID: 14499
05-20 00:00:39.499 14499 14499 E AndroidRuntime: java.lang.OutOfMemoryError: Failed to allocate a 478821936 byte allocation with 9613724 free bytes and 242MB until OOM
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at dalvik.system.VMRuntime.newNonMovableArray(Native Method)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.graphics.BitmapFactory.nativeDecodeAsset(Native Method)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.graphics.BitmapFactory.decodeStream(BitmapFactory.java:620)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.graphics.BitmapFactory.decodeResourceStream(BitmapFactory.java:455)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.graphics.drawable.Drawable.createFromResourceStream(Drawable.java:1155)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.content.res.ResourcesImpl.loadDrawableForCookie(ResourcesImpl.java:720)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.content.res.ResourcesImpl.loadDrawable(ResourcesImpl.java:571)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.content.res.Resources.getDrawable(Resources.java:771)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.graphics.drawable.Icon.loadDrawableInner(Icon.java:316)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.graphics.drawable.Icon.loadDrawable(Icon.java:272)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.graphics.drawable.Icon.loadDrawableAsUser(Icon.java:380)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at com.android.systemui.statusbar.StatusBarIconView.getIcon(StatusBarIconView.java:227)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at com.android.systemui.statusbar.StatusBarIconView.getIcon(StatusBarIconView.java:211)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at com.android.systemui.statusbar.StatusBarIconView.updateDrawable(StatusBarIconView.java:198)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at com.android.systemui.statusbar.StatusBarIconView.set(StatusBarIconView.java:157)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at com.android.systemui.statusbar.BaseStatusBar.createIcon(BaseStatusBar.java:2272)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at com.android.systemui.statusbar.BaseStatusBar.createNotificationViews(BaseStatusBar.java:2238)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at com.android.systemui.statusbar.phone.PhoneStatusBar.addNotification(PhoneStatusBar.java:1905)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at com.android.systemui.statusbar.BaseStatusBar$7$1.run(BaseStatusBar.java:631)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.os.Handler.handleCallback(Handler.java:751)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:95)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.os.Looper.loop(Looper.java:154)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:6290)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886)
05-20 00:00:39.499 14499 14499 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776)
05-20 00:00:39.499 14499 14499 D AppTracker: App Event: crash
05-20 00:00:39.508 1399 3175 W ActivityManager: Process com.android.systemui has crashed too many times: killing!
```

When I test to send a notification from the firebase console, It works.

I hope you have an idea.

Great package by the way !

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the notification on the reported OnePlus 3 running Android 7.1.1 and compare the package's server-generated notification with the Firebase Console notification. Use the supplied Android System UI stack trace and server log as the initial evidence; no repository file, test, or code entry point is identified, so done is not clearly defined.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, javascript
Domain
mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.