Library crash after play-services-gcm:12.0.0 update.
See original GitHub issueMy app started crashing after updating com.google.android:play-services-gcm from 11.8.0 to 12.0.0. Crash appears in your library. Error is following:
java.lang.RuntimeException: Unable to create application: java.lang.IllegalArgumentException: The GcmTaskService class you provided com.evernote.android.job.gcm.PlatformGcmService does not seem to support receiving com.google.android.gms.gcm.ACTION_TASK_READY
Tested on 4.4.2.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:7
- Comments:39 (1 by maintainers)
Top Results From Across the Web
xcode14:Library not loaded: /usr/l… | Apple Developer Forums
If your app experienced this crash after uploading to the App Store using Xcode 13 with bitcode enabled, your app experienced the crash...
Read more >JW Library and Windows 11 22H2 Update and Feature update ...
Xaml.dll file that JW Library needs is altered. This change is the cause of the crash upon opening and not allowing .JWPub files...
Read more >SmsRetrieverClient Crash last update - Stack Overflow
android.gms artifacts. And now I am getting crash when using SmsRetriever. Since I am specifying null in startSmsUserConsent(). UPDATE: I use:
Read more >Why is forScore crashing on launch?
Crashing After an iOS Update. Occasionally, updates to iOS introduce features or changes that make older versions of forScore incompatible.
Read more >Fusion 360 crashes when launching the Tool Library
Remove the xml files in %LOCALAPPDATA%\Fusion 360 CAM\Settings. Check the graphics card / drivers. Update graphics drivers to the latest. In ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I temporarily fixed it with by adding the service declaration in manifest:
I spent a couple of hours debugging. This is what I found:
GcmNetworkManager
behavior changed in Play services v 12.x and later. It callsPackageManager.queryIntentServices
to find registered services which havecom.google.android.gms.gcm.ACTION_TASK_READY
. This is not new.What’s new is
GcmNetworkManager
now runs an additional check on the returnedList<ResolveInfo>
. It checks ifresolveInfo.serviceInfo.enabled == true
. Per official Android documentation the values inserviceInfo
are from service declaration in app manifest.android-job
declarescom.evernote.android.job.gcm.PlatformGcmService
in the library manifest withandroid:enabled="false"
. The service is enabled programatically via code. The check in (2) only sees the static value in the manifest.This is why the workaround posted by @maximrahlis (https://github.com/evernote/android-job/issues/415#issuecomment-380017997) works. It basically zeroes out
android:enabled="false"
in the library manifest