Plugins being reset because of load time


#1

I am having some issues with an Ionic app I am trying to develop, especially around getting the push notifications to work. I have been attempting to get the Push token to register through Ionic using the ionic-web-client library.

When I run the project through Xcode, this is the log:

Apache Cordova native platform version 4.3.1 is starting.
2016-12-31 13:24:53.118638 com.playground.test.dev[11334:3062574] Multi-tasking -> Device: YES, App: YES
2016-12-31 13:24:53.364238 com.playground.test.dev[11334:3062574] Using UIWebView
2016-12-31 13:24:53.369006 com.playground.test.dev[11334:3062574] [CDVTimer][handleopenurl] 0.171959ms
2016-12-31 13:24:53.374899 com.playground.test.dev[11334:3062574] [CDVTimer][intentandnavigationfilter] 5.698979ms
2016-12-31 13:24:53.375233 com.playground.test.dev[11334:3062574] [CDVTimer][gesturehandler] 0.168025ms
2016-12-31 13:24:53.415310 com.playground.test.dev[11334:3062574] [CDVTimer][statusbar] 39.875031ms
2016-12-31 13:24:53.417447 com.playground.test.dev[11334:3062574] [CDVTimer][keyboard] 1.947999ms
2016-12-31 13:24:53.460481 com.playground.test.dev[11334:3062574] [CDVTimer][splashscreen] 42.874992ms
2016-12-31 13:24:53.460599 com.playground.test.dev[11334:3062574] [CDVTimer][TotalPluginStartup] 91.865003ms
2016-12-31 13:24:53.976602 com.playground.test.dev[11334:3062574] createNotificationChecker
2016-12-31 13:24:53.976684 com.playground.test.dev[11334:3062574] not coldstart
2016-12-31 13:24:53.980421 com.playground.test.dev[11334:3062574] active
2016-12-31 13:24:53.983104 com.playground.test.dev[11334:3062574] PushPlugin skip clear badge
2016-12-31 13:24:55.147607 com.playground.test.dev[11334:3062574] Resetting plugins due to page load.
2016-12-31 13:24:56.294580 com.playground.test.dev[11334:3062574] Finished load of: file:///var/containers/Bundle/Application/0C979B9E-DA07-41D7-BB2D-5C4569BF874B/TEST%20DEV.app/www/index.html#/splash
2016-12-31 13:24:57.359684 com.playground.test.dev[11334:3062574] Ionic Core: plugins are ready

Here is an output of my Ionic environment:

Your system information:

Cordova CLI: 6.4.0
Gulp version:  CLI version 3.9.1
Gulp local:   Local version 3.9.1
Ionic Framework Version: 1.3.1-nightly-4219
Ionic CLI Version: 2.1.1
Ionic App Lib Version: 2.1.1
ios-deploy version: 1.9.0 
ios-sim version: 5.0.8 
OS: Mac OS X Sierra
Node Version: v4.6.0
Xcode version: Xcode 8.2.1 Build version 8C1002 

Here is my current plugins:

cordova-plugin-console 1.0.4 "Console"
cordova-plugin-device 1.1.3 "Device"
cordova-plugin-inappbrowser 1.6.1 "InAppBrowser"
cordova-plugin-splashscreen 4.0.1 "Splashscreen"
cordova-plugin-statusbar 2.2.0 "StatusBar"
cordova-plugin-whitelist 1.3.0 "Whitelist"
ionic-plugin-keyboard 2.2.1 "Keyboard"
phonegap-plugin-push 1.8.4 "PushPlugin"

Update: Here is my config.xml

<?xml version='1.0' encoding='utf-8'?>
<widget id="com.playground.test.dev" version="1.0.1" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
    <name>DEV TEST PROJECT</name>
    <description>
        An Ionic Framework and Cordova project.
    </description>
    <author email="XXXXXXXXXX" href="XXXXXXXXXXm">
      XXXXXXXXXX
    </author>
    <content src="index.html" />
    <access origin="*" />
    <access origin="http://*" />
    <access origin="https://*" />
    <allow-navigation href="http://*/*" />
    <allow-navigation href="https://*/*" />
    <allow-intent href="http://*" />
    <allow-intent href="https://*" />
    <allow-intent href="tel:*" />
    <preference name="webviewbounce" value="false" />
    <preference name="UIWebViewBounce" value="false" />
    <preference name="DisallowOverscroll" value="true" />
    <preference name="android-minSdkVersion" value="16" />
    <preference name="BackupWebStorage" value="none" />
    <preference name="SplashScreen" value="screen" />
    <preference name="SplashScreenDelay" value="3000" />
    <preference name="orientation" value="portrait" />
    <feature name="StatusBar">
        <param name="ios-package" onload="true" value="CDVStatusBar" />
    </feature>
    <platform name="ios">
        <icon height="57" src="resources/ios/icon/icon.png" width="57" />
        <icon height="114" src="resources/ios/icon/icon@2x.png" width="114" />
        <icon height="40" src="resources/ios/icon/icon-40.png" width="40" />
        <icon height="80" src="resources/ios/icon/icon-40@2x.png" width="80" />
        <icon height="120" src="resources/ios/icon/icon-40@3x.png" width="120" />
        <icon height="50" src="resources/ios/icon/icon-50.png" width="50" />
        <icon height="100" src="resources/ios/icon/icon-50@2x.png" width="100" />
        <icon height="60" src="resources/ios/icon/icon-60.png" width="60" />
        <icon height="120" src="resources/ios/icon/icon-60@2x.png" width="120" />
        <icon height="180" src="resources/ios/icon/icon-60@3x.png" width="180" />
        <icon height="72" src="resources/ios/icon/icon-72.png" width="72" />
        <icon height="144" src="resources/ios/icon/icon-72@2x.png" width="144" />
        <icon height="76" src="resources/ios/icon/icon-76.png" width="76" />
        <icon height="152" src="resources/ios/icon/icon-76@2x.png" width="152" />
        <icon height="167" src="resources/ios/icon/icon-83.5@2x.png" width="167" />
        <icon height="29" src="resources/ios/icon/icon-small.png" width="29" />
        <icon height="58" src="resources/ios/icon/icon-small@2x.png" width="58" />
        <icon height="87" src="resources/ios/icon/icon-small@3x.png" width="87" />
        <splash height="1136" src="resources/ios/splash/Default-568h@2x~iphone.png" width="640" />
        <splash height="1334" src="resources/ios/splash/Default-667h.png" width="750" />
        <splash height="960" src="resources/ios/splash/Default@2x~iphone.png" width="640" />
        <splash height="480" src="resources/ios/splash/Default~iphone.png" width="320" />
    </platform>
    <platform name="android">
        <icon density="ldpi" src="resources/android/icon/drawable-ldpi-icon.png" />
        <icon density="mdpi" src="resources/android/icon/drawable-mdpi-icon.png" />
        <icon density="hdpi" src="resources/android/icon/drawable-hdpi-icon.png" />
        <icon density="xhdpi" src="resources/android/icon/drawable-xhdpi-icon.png" />
        <icon density="xxhdpi" src="resources/android/icon/drawable-xxhdpi-icon.png" />
        <icon density="xxxhdpi" src="resources/android/icon/drawable-xxxhdpi-icon.png" />
        <splash density="land-ldpi" src="resources/android/splash/drawable-land-ldpi-screen.png" />
        <splash density="land-mdpi" src="resources/android/splash/drawable-land-mdpi-screen.png" />
        <splash density="port-ldpi" src="resources/android/splash/drawable-port-ldpi-screen.png" />
        <splash density="port-mdpi" src="resources/android/splash/drawable-port-mdpi-screen.png" />
        <splash density="port-hdpi" src="resources/android/splash/drawable-port-hdpi-screen.png" />
        <splash density="port-xhdpi" src="resources/android/splash/drawable-port-xhdpi-screen.png" />
    </platform>
    <icon src="resources/ios/icon/icon-small@3x.png" />
    <plugin name="phonegap-plugin-push" spec="~1.8.4">
        <variable name="SENDER_ID" value="XXXXXXXXXX" />
    </plugin>
</widget>

Any thoughts around what may be causing the Push notifications to not register and causing the long load times?

Interestingly enough, the Push notifications do get registered when I run the app through Google Chrome.

Thanks for any help.


#2

Updated the original post to include my config.xml, if that will help.

Thanks!