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

Unable to install the app on Android 5 and iOs8 #731

Closed
vousys opened this issue Mar 21, 2016 · 13 comments
Closed

Unable to install the app on Android 5 and iOs8 #731

vousys opened this issue Mar 21, 2016 · 13 comments

Comments

@vousys
Copy link

vousys commented Mar 21, 2016

Hi Simon! i compile the app perfectly from https://build.phonegap.com/ but when i try to install it on my android device 5.0 it won't install. No error shows except "Can't install the app"
If I remove the lines to invoke your plugin from the config.xml, it installs fine.

 <gap:plugin name="phonegap-plugin-push"  source="npm">
        <param name="SENDER_ID" value="THE-ID"/>
    </gap:plugin>

I can't find any other issue here about that so I have to ask you for help.
My complete config is this:

    <preference name="permissions" value="none"/>
    <preference name="DisallowOverscroll" value="true" />
    <preference name="phonegap-version"  /> <!--  value="cli-5.2.0"  andaba bien 3.7.0 !-->
    <preference name="android-maxSDKVersion" value="" />
    <preference name="android-targetSdkVersion" value="12" />  
    <preference name="orientation" value="auto" />
    <preference name="target-device" value="universal" />
    <preference name="fullscreen" value="false" />
    <preference name="android-minSDKVersion" value="17" /><!-- min android version: 4.2 !-->
    <preference name="android-installLocation" value="auto" />
    <preference name="show-splash-screen-spinner" value="true" />
    <preference name="auto-hide-splash-screen" value="true" />
    <preference name="splash-screen-duration" value="2500" />
    <preference name="exit-on-suspend" value="true" />
    <preference name="load-url-timeout" value="25000" />
    <preference name="deployment-target" value="8.0" /> <!-- min iOS version 7 !-->
    <preference name="android-build-tool" value="gradle" />

    <!-- para el fileupload !-->
    <preference name="AndroidPersistentFileLocation"        value="Internal" />
    <preference name="AndroidPersistentFileLocation"        value="Compatibility" />
    <preference name="iosPersistentFileLocation"            value="Library" />
    <preference name="iosPersistentFileLocation"            value="Compatibility" />
    <gap:plugin name="cordova-plugin-file"                  source="npm" /> 
    <gap:plugin name="cordova-plugin-file-transfer"         source="npm" /> 
    <access origin="cdvfile://*" />
    <preference name="iosExtraFilesystems"                  value="library,library-nosync,documents,documents-nosync,cache,bundle,root" />
    <preference name="AndroidExtraFilesystems"              value="files,files-external,documents,sdcard,cache,cache-external,root" />

    <!-- para el fileupload !-->


    <gap:plugin name="ionic-plugin-keyboard"                    source="npm"    />
    <gap:plugin name="cordova-plugin-splashscreen"              version="2.1.0"     source="npm" />
    <gap:plugin name="cordova-plugin-whitelist"                 version="1.0.0"     source="npm" />
    <gap:plugin name="cordova-plugin-contacts"                                      source="npm" />
    <gap:plugin name="cordova-plugin-x-socialsharing"                               source="npm" /> 
    <gap:plugin name="cordova-plugin-geolocation"               version="1.0.1"     source="npm" />
    <gap:plugin name="cordova-plugin-calendar"                                       source="npm" />
    <gap:plugin name="cordova-plugin-device"                                        source="npm" /> 

    <gap:plugin name="phonegap-plugin-push"                                         source="npm">
        <param name="SENDER_ID" value="THE-ID"/>
    </gap:plugin>

    <access origin="tel:*" launch-external="yes" /> 
    <access origin="geo:*" launch-external="yes" />
    <access origin="*"/>
</widget>

I used to use your plugin in another project wich still works and use phonegap 3.7.0 (i didn't recompile it)

I did the following testing:
remove all the plugins except those, but still can't install it on Android 5 and iOs 8

    <gap:plugin name="cordova-plugin-whitelist"                 source="npm" />
    <gap:plugin name="cordova-plugin-device"                    source="npm" /> 
    <gap:plugin name="cordova-plugin-splashscreen"              source="npm" /> 
 <gap:plugin name="phonegap-plugin-push" source="npm">
        <param name="SENDER_ID" value="XXXX"/>
    </gap:plugin>
@vousys vousys changed the title Unable to install the app on Android 5. Unable to install the app on Android 5 and iOs8 Mar 21, 2016
@macdonst
Copy link
Member

@vousys do you have two apps with the same bundle ID on your device?

@vousys
Copy link
Author

vousys commented Mar 22, 2016

​Hi Simon, no,
​I've checked everything, it only lets me install it, ​
if I remove the push plugin

@macdonst
Copy link
Member

@vousys I'd like to see the terminal output when you run the adb install -r myapp-release.apk command. As well consider doing adb uninstall com.mypackage.app before trying to do an install.

@vousys
Copy link
Author

vousys commented Mar 22, 2016

Hi Simon, I don't use this, I scan the QR code and install it on the device, and for iOs I use diawi to upload.
I try with an empty config with only this information: (new ID, new Version, none of parameters) but nothing works. I remove the app from build.phonegap.com and then upload again, but the https://build.phonegap.com/apps/1977569/builds says:
"Oh geez. Your build failed. Sorry, but a problem occurred on the build server"

<?xml version="1.0" encoding="UTF-8"?>
<widget xmlns     = "http://www.w3.org/ns/widgets"
        xmlns:gap = "http://phonegap.com/ns/1.0"
        id          = "XXX"
        versionCode = "49"
        version   = "1.0.2"> 
    <name>XXX</name> 
    <description><![CDATA[XXXX]]></description> 

    <preference name="android-build-tool" value="gradle" />
    <preference name="android-minSDKVersion" value="17" />  <!-- min android version: 4.2  !-->
    <preference name="deployment-target" value="8.0" />     <!-- min iOS version 7  !-->

    <preference name="permissions" value="none"/> 
    <preference name="phonegap-version" value="cli-5.2.0" />
    <preference name="android-maxSDKVersion" value="" />
    <preference name="android-targetSdkVersion" value="12" />  

    <!-- PLUGINS !-->
    <gap:plugin name="cordova-plugin-whitelist" source="npm" />

    <gap:plugin name="cordova-plugin-push" source="npm">
        <param name="SENDER_ID" value="XXX"/>
    </gap:plugin> 

</widget>

My built information:
App ID
1977569

Version
1.0.2

Owned by
xXXX

PhoneGap (iOS / Android / Windows)
cli-5.2.0 (3.9.1 / 4.1.1 / 3.8.1)

Plugin Source Version Installed Latest Platforms
cordova-plugin-push npm * n/a n/a android,ios,winphone
cordova-plugin-whitelist npm * n/a n/a android,ios,winphone

  • Installed version of plugins will only be available after a successful build.

@vousys
Copy link
Author

vousys commented Mar 22, 2016

If I comment your plugin, I can compile it, check please
App ID
1977569

Version
1.0.2

Owned by
XXXX

PhoneGap (iOS / Android / Windows)
cli-5.2.0 (3.9.1 / 4.1.1 / 3.8.1)

Source
.zip package

Last built (2)
1 minute

Plugin Source Version Installed Latest Platforms
cordova-plugin-whitelist npm * 1.2.1 n/a android,ios,winphone

  • Installed version of plugins will only be available after a successful build. Update your config.xml with the snippet below to lock your plugins to the specific version used in this build:

And the config.xml

<?xml version="1.0" encoding="UTF-8"?>
<widget xmlns     = "http://www.w3.org/ns/widgets"
        xmlns:gap = "http://phonegap.com/ns/1.0"
        id          = "XXX"
        versionCode = "49"
        version   = "1.0.2"> 
    <name>XXX</name> 
    <description><![CDATA[XXXX]]></description> 

    <preference name="android-build-tool" value="gradle" />
    <preference name="android-minSDKVersion" value="17" />  <!-- min android version: 4.2  !-->
    <preference name="deployment-target" value="8.0" />     <!-- min iOS version 7  !-->

    <preference name="permissions" value="none"/> 
    <preference name="phonegap-version" value="cli-5.2.0" />
    <preference name="android-maxSDKVersion" value="" />
    <preference name="android-targetSdkVersion" value="12" />  

    <!-- PLUGINS !-->
    <gap:plugin name="cordova-plugin-whitelist" source="npm" />

   <!-- <gap:plugin name="cordova-plugin-push" source="npm">
        <param name="SENDER_ID" value="XXX"/>
    </gap:plugin> !-->

</widget>

Maybe the Build online has a bug

@macdonst
Copy link
Member

@vousys you are using the wrong plugin ID, notice your config.xml has cordova-plugin-push:

<gap:plugin name="cordova-plugin-push" source="npm">
        <param name="SENDER_ID" value="XXX"/>
</gap:plugin>

but it should be phonegap-plugin-push.

@vousys
Copy link
Author

vousys commented Mar 22, 2016

Hi Simon. My mistake, I was so tired testing and removing plugins and settings to make it work since yesterday.
I recompile it with the right tag, the build finished ok but when i try to install the app it says: Aplication not installed. I don't know what else to test.

@macdonst
Copy link
Member

@vousys I think you should download the .apk file and try to install it using the adb tool. You will get a better error message. I'm pretty sure there is another app on your device using the same ID.

@vousys
Copy link
Author

vousys commented Mar 22, 2016

it's imposible because I put the name XXXFuckingTesting .
I'll check how to install it using that because it sounds me that's a
native tool for develop in android

2016-03-22 11:03 GMT-03:00 Simon MacDonald notifications@github.com:

@vousys https://github.com/vousys I think you should download the .apk
file and try to install it using the adb tool. You will get a better
error message. I'm pretty sure there is another app on your device using
the same ID.


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
#731 (comment)

@vousys
Copy link
Author

vousys commented Mar 22, 2016

Simon, if it was a problem with the ID, I shouldn't be able to install it without the push plugin, and I could.

@vousys
Copy link
Author

vousys commented Mar 23, 2016

Hi Simon! I create a new empty project only with the files of your example (https://github.com/phonegap/phonegap-plugin-push/tree/master/example/www) and this little config , I compile it fine but can't install it on my device motox xt1058 android lollipop
and happens the same in my iphone 4, ios8

<?xml version="1.0" encoding="UTF-8"?>
<widget xmlns     = "http://www.w3.org/ns/widgets"
        xmlns:gap = "http://phonegap.com/ns/1.0"
        id          = "mitest.com.testing"
        versionCode = "49"
        version   = "1.0.2">

    <name>Testing</name>

    <description><![CDATA[testing]]></description>

    <author href="http://www.tttt.com" email="info@ttt.com">
        ttt 
    </author>

    <preference name="android-build-tool" value="gradle" />
    <preference name="android-minSDKVersion" value="17" />  <!-- min android version: 4.2  !-->
    <preference name="deployment-target" value="8.0" />     <!-- min iOS version 7  !-->


    <preference name="permissions" value="none"/> 
    <preference name="phonegap-version" value="cli-5.2.0" />
    <preference name="android-maxSDKVersion" value="" />
    <preference name="android-targetSdkVersion" value="12" />  


    <!-- PLUGINS !-->
    <gap:plugin name="cordova-plugin-whitelist" source="npm" />
    <gap:plugin name="cordova-plugin-device"    source="npm" />  


    <gap:plugin name="phonegap-plugin-push" source="npm">
        <param name="SENDER_ID" value="XXX"/>
        <!--<param name="GOOGLE_APP_ID" value="1:xxxx:ios:aaa"/>!-->
    </gap:plugin> 



        <gap:platform name="ios" />
        <gap:platform name="android" />

    <access origin="tel:*" launch-external="yes" /> 
    <access origin="geo:*" launch-external="yes" />
    <access origin="*"/>
</widget>

@vousys
Copy link
Author

vousys commented Mar 23, 2016

Hi simon, I found the solution !!! reading and testing all the other issues, but please check because something is wrong with the default version of phonegap and plugin push

At this issue #741 they use

<preference name="phonegap-version" value="cli-5.4.1" />
<plugin name="phonegap-plugin-push" spec="~1.4.5" source="npm">

I changed that in my config and it works

@lock
Copy link

lock bot commented Jun 5, 2018

This thread has been automatically locked.

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

No branches or pull requests

2 participants