Skip to content
This repository has been archived by the owner on Sep 4, 2020. It is now read-only.

Cannot find symbol variable INSTANCE_ID_SCOPE #477

Closed
mapeveri opened this issue Jan 5, 2016 · 15 comments
Closed

Cannot find symbol variable INSTANCE_ID_SCOPE #477

mapeveri opened this issue Jan 5, 2016 · 15 comments

Comments

@mapeveri
Copy link

mapeveri commented Jan 5, 2016

Hi, after install this plugin and to build return this error "Error:(30, 41) error: cannot find symbol variable INSTANCE_ID_SCOPE"

What can be?

Thanks!

@macdonst macdonst closed this as completed Jan 6, 2016
@mapeveri
Copy link
Author

mapeveri commented Jan 6, 2016

Hi @macdonst I have installed it and you say.

This 4 items with corresponding versions.

Android Support Library version 23 or greater
Android Support Repository version 20 or greater
Google Play Services version 27 or greater
Google Repository version 22 or greater

Thanks!

@mapeveri
Copy link
Author

mapeveri commented Jan 6, 2016

image

@macdonst
Copy link
Member

macdonst commented Jan 6, 2016

@mapeveri do me a favor and run android update sdk --no-ui --filter "extra" from the command line and try rebuilding.

@mapeveri
Copy link
Author

mapeveri commented Jan 6, 2016

@macdonst I run again and same error:

src\com\adobe\phonegap\push\RegistrationIntentService.java:30: error: cannot fin
d symbol
GoogleCloudMessaging.INSTANCE_ID_SCOPE, null);
^
symbol: variable INSTANCE_ID_SCOPE
location: class GoogleCloudMessaging
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
1 error
FAILED

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':compileDebugJava'.

    Compilation failed; see the compiler error output for details.

@mapeveri
Copy link
Author

mapeveri commented Jan 6, 2016

@macdonst any idea?. You can reopen this issue?.

Thank you

@kest85
Copy link

kest85 commented Jan 19, 2016

I have the same issue. Any solutions?

@macdonst
Copy link
Member

@kest85 I promise you that it is something wrong with your Android build environment. It's near impossible for me to debug from here.

@fredgalvao
Copy link
Collaborator

Or related to the possible fact that you're trying to compile it through a badly-configurated IDE, as Eclipse or IntellijIDEA or even Android Studio.

@kest85
Copy link

kest85 commented Jan 20, 2016

Removing googleplayservices plugin fixed the problem.

@furyscript
Copy link

I have the same error, but I need cordova-plugin-googleplayservices. How can I resolve?

@fredgalvao
Copy link
Collaborator

Ask that plugin's author to upgrade to gradle-style dependency management. @furyscript

@furyscript
Copy link

I resolve downgrade to phonegap-plugin-push@1.3.0. Compilation work, push notification receveid but not showing in emulator, is it normal? @macdonst

@andresarslanian
Copy link

andresarslanian commented Jun 16, 2016

Hi everyone... although this post is rather old, I was still experiencing the problem today.

As @macdonst said, the plugin is working, he tried it in different machines and it's working.

Digging around why I still had this problem, I saw that the plugin clearly states that it requires: Google Play Services version 27 or greater

I did a cordova plugin list and saw the following:

cordova-plugin-app-preferences 0.7.7 "AppPreferences"
cordova-plugin-camera 2.2.0 "Camera"
cordova-plugin-compat 1.0.0 "Compat"
cordova-plugin-console 1.0.3 "Console"
cordova-plugin-device 1.1.2 "Device"
cordova-plugin-facebook4 1.7.0 "Facebook Connect"
cordova-plugin-file 4.2.0 "File"
cordova-plugin-file-transfer 1.5.1 "File Transfer"
cordova-plugin-google-analytics 0.7.1 "Google Universal Analytics Plugin"
cordova-plugin-googleplayservices 19.0.3 "Google Play Services for Android"
cordova-plugin-image-picker 1.0.8 "ImagePicker"
cordova-plugin-inappbrowser 1.4.0 "InAppBrowser"
cordova-plugin-network-information 1.2.1 "Network Information"
cordova-plugin-splashscreen 3.2.2 "Splashscreen"
cordova-plugin-whitelist 1.2.2 "Whitelist"
cordova-plugin-x-socialsharing 5.1.0 "SocialSharing"
cordova-sqlite-storage 1.2.1 "Cordova sqlite storage plugin (core version)"
ionic-plugin-keyboard 2.0.1 "Keyboard"

This is, although I had everything up to date with @macdonst suggestion of doing:
android update sdk --no-ui --filter "extra"

I still (don't know why) but had in my config.xml the following line:
<plugin name="cordova-plugin-googleplayservices" spec="~19.0.3" />

So what I did was removing that line, then:
cordova plugin rm cordova-plugin-googleplayservices

and voilà!

Hope it helps

@lock
Copy link

lock bot commented Jun 4, 2018

This thread has been automatically locked.

@lock lock bot locked as resolved and limited conversation to collaborators Jun 4, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

6 participants