Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IllegalAccessError / conflict with GCM 8.3.0 library #55

Closed
jewom opened this issue Jul 4, 2017 · 5 comments
Closed

IllegalAccessError / conflict with GCM 8.3.0 library #55

jewom opened this issue Jul 4, 2017 · 5 comments
Assignees
Labels
Bug Unexpected/bad behavior Status - Fix Released A bug fix that has been released
Milestone

Comments

@jewom
Copy link

jewom commented Jul 4, 2017

Hi,

First, thanks for all, I love your library and it's working good with a new project :)

When I add the library in an old project, after the compilation I have this error :

FATAL EXCEPTION: IntentService[GCM] Process: my.app, PID: 7667 java.lang.IllegalAccessError: Method 'void android.support.v4.content.ContextCompat.()' is inaccessible to class 'com.google.android.gms.iid.zzd' (declaration of 'com.google.android.gms.iid.zzd' appears in /data/app/my.app-1/base.apk:classes2.dex) at com.google.android.gms.iid.zzd.zzdL(Unknown Source) at com.google.android.gms.iid.zzd.(Unknown Source) at com.google.android.gms.iid.zzd.(Unknown Source) at com.google.android.gms.iid.InstanceID.zza(Unknown Source) at com.google.android.gms.iid.InstanceID.getInstance(Unknown Source) at gcm.RegistrationIntentService.onHandleIntent(RegistrationIntentService.java:54) at android.app.IntentService$ServiceHandler.handleMessage(IntentService.java:67) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:154) at android.os.HandlerThread.run(HandlerThread.java:61)

This is the line of the problem :

InstanceID instanceID = InstanceID.getInstance(this);
I have look the reason of this error and it seem it's because I use a version too old of my play-services.

compile 'com.google.android.gms:play-services:8.3.0'
But it's working without adding the lib wisefy so how can I isolate this problem because I don't want to update my library ?

@isuPatches isuPatches self-assigned this Jul 4, 2017
@isuPatches isuPatches added the Bug Unexpected/bad behavior label Jul 4, 2017
@isuPatches
Copy link
Owner

isuPatches commented Jul 4, 2017

Oh! Interesting...yes, there is a conflict that is coming from the compile 'com.android.support:appcompat-v7:25.3.1' in WiseFy. I don't think we actually need the support libraries for anything at this time, so I'm okay with removing it for now until it's actually in use.

I'll push an update, but an alternative would be to exclude the version of appcompat-v7 that WiseFy is bringing in.

@jewom
Copy link
Author

jewom commented Jul 4, 2017

Thanks a lot !
How can I exclude the version of appcompat-v7 that WiseFy is bringing in ?

isuPatches added a commit that referenced this issue Jul 4, 2017
@isuPatches isuPatches mentioned this issue Jul 4, 2017
@isuPatches
Copy link
Owner

isuPatches commented Jul 4, 2017

This should do it until I release 1.0.10:

compile ('com.isupatches:wisefy:1.0.9') {
      exclude module: 'appcompat-v7'
}

Thanks for reporting everything :)

@jewom
Copy link
Author

jewom commented Jul 4, 2017

Thanks it's working :)

@isuPatches isuPatches changed the title IllegalAccessError when I add the library IllegalAccessError / conflict with GCM 8.3.0 library Jul 4, 2017
@isuPatches
Copy link
Owner

Should be okay in 1.0.10 as well

@isuPatches isuPatches added 1.x Status - Released Work that has been released labels Dec 10, 2017
@isuPatches isuPatches added this to the 1.0.10 milestone Dec 14, 2019
@isuPatches isuPatches added Status - Fix Released A bug fix that has been released and removed Status - Released Work that has been released labels Jan 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Unexpected/bad behavior Status - Fix Released A bug fix that has been released
Projects
None yet
Development

No branches or pull requests

2 participants