I've set the below code in PushwooshiOS.js pushNotification.onDeviceReady({pw_appid:"34FA9-60E57"}); which is Application code from the PushWoosh console, also i've created a development provisioning profile and used the Auto mode to generate the certificates and then used xCode to install the app made using the sample code here https://github.com/Pushwoosh/pushwoosh-phonegap-cordova-sample alt text


below is the console log from xCode....

2016-02-05 13:47:13.620 pushwoosh-ionic-sample[4904:3868615] [PW] [I] +[UIApplication(Pushwoosh)] Pushwoosh: Initializing application runtime 2016-02-05 13:47:13.656 pushwoosh-ionic-sample[4904:3868615] DiskCookieStorage changing policy from 2 to 0, cookie file: file:///private/var/mobile/Containers/Data/Application/3DF5FFB2-6A5E-45AC-9FE0-D29A6ABB5D17/Library/Cookies/Cookies.binarycookies 2016-02-05 13:47:13.899 pushwoosh-ionic-sample[4904:3868615] You've implemented -[<uiapplicationdelegate> application:didReceiveRemoteNotification:fetchCompletionHandler:], but you still need to add "remote-notification" to the list of your supported UIBackgroundModes in your Info.plist. 2016-02-05 13:47:13.916 pushwoosh-ionic-sample[4904:3868615] Apache Cordova native platform version 4.0.1 is starting. 2016-02-05 13:47:13.918 pushwoosh-ionic-sample[4904:3868615] Multi-tasking -> Device: YES, App: YES 2016-02-05 13:47:14.288 pushwoosh-ionic-sample[4904:3868615] Using UIWebView 2016-02-05 13:47:14.292 pushwoosh-ionic-sample[4904:3868615] [CDVTimer][handleopenurl] 0.128984ms 2016-02-05 13:47:14.296 pushwoosh-ionic-sample[4904:3868615] [CDVTimer][intentandnavigationfilter] 3.758967ms 2016-02-05 13:47:14.297 pushwoosh-ionic-sample[4904:3868615] [CDVTimer][gesturehandler] 0.126004ms 2016-02-05 13:47:14.297 pushwoosh-ionic-sample[4904:3868615] [CDVTimer][TotalPluginStartup] 4.662037ms 2016-02-05 13:47:14.740 pushwoosh-ionic-sample[4904:3868615] [PW] [I] -[PushNotificationManager] Will show push notifications alert: 1 2016-02-05 13:47:15.293 pushwoosh-ionic-sample[4904:3868615] [PW] [I] -[PWLocationTracker] location services authorization status has not been determined yet 2016-02-05 13:47:15.379 pushwoosh-ionic-sample[4904:3868615] Resetting plugins due to page load. 2016-02-05 13:47:15.552 pushwoosh-ionic-sample[4904:3868691] [PW] [I] -[PWRequestManager] x | Pushwoosh request: | Url: https://cp.pushwoosh.com/json/1.3/registerUser | Payload: {"request":{"device_type":1,"application":"","userId":"CE7D06CD-4A56-4D46-8F68-B7DDDF555F3B","v":"3.1.1.434","hwid":"CE7D06CD-4A56-4D46-8F68-B7DDDF555F3B"}} | Status: "200 no error" | Response: {"status_code": 210, "status_message": "Request format is not valid."} x 2016-02-05 13:47:15.825 pushwoosh-ionic-sample[4904:3868669] [PW] [I] -[PWRequestManager] x | Pushwoosh request: | Url: https://cp.pushwoosh.com/json/1.3/getInApps | Payload: {"request":{"device_type":1,"language":"en-IN","application":"","userId":"CE7D06CD-4A56-4D46-8F68-B7DDDF555F3B","v":"3.1.1.434","hwid":"CE7D06CD-4A56-4D46-8F68-B7DDDF555F3B"}} | Status: "200 no error" | Response: {"status_code":210,"status_message":"Application not found","response":null} x 2016-02-05 13:47:15.831 pushwoosh-ionic-sample[4904:3868693] [PW] [I] -[PWRequestManager] x | Pushwoosh request: | Url: https://cp.pushwoosh.com/json/1.3/applicationOpen | Payload: {"request":{"userId":"CE7D06CD-4A56-4D46-8F68-B7DDDF555F3B","app_version":"0.0.1","hwid":"CE7D06CD-4A56-4D46-8F68-B7DDDF555F3B","language":"en","os_version":"9.2.1","package":"in.greysoftware.ionicpushwoosh","v":"3.1.1.434","application":"","device_type":1,"jailbroken":0,"device_model":"iPhone7,2"}} | Status: "200 no error" | Response: {"status_code":210,"status_message":"Application not found","response":null} x 2016-02-05 13:47:15.836 pushwoosh-ionic-sample[4904:3868693] [PW] [I] -[PushNotificationManager] sending appOpen failed 2016-02-05 13:47:16.161 pushwoosh-ionic-sample[4904:3868615] Finished load of: file:///var/mobile/Containers/Bundle/Application/96DA0C9D-3000-485A-A2D3-823FD4FB377F/pushwoosh-ionic-sample.app/www/index.html#/tab/dash

asked 06 Feb '16, 07:26
snehoo's gravatar image

snehoo
212

12next »

Hi!

May I ask you a couple of questions to clarify things?

  1. Does the issue persist if you launch the application second time?
  2. Is there the Application Code in the /registerDevice request?
  3. Could you please specify the version of the plugin and the version of the Cordova itself?
  4. Have you tried our Sample App? Is the issue reproducible with it? Here is the link to the Cordova Sample: https://github.com/Pushwoosh/pushwoosh-phonegap-plugin
  5. By any chance, do you know whether it works for Android?
permanent link
answered 10 Mar '16, 12:05
Nikolai's gravatar image

Nikolai
3585

I have the same problem

permanent link
answered 03 Mar '16, 01:33
jQrgen's gravatar image

jQrgen
2614

Hi Nikolai, thanks for answering.

1. Does the issue persist if you launch the application second time?

Yes

2. Is there the Application Code in the /registerDevice request?

The code is set up like this:

this.init = function(){ pushNot = window.plugins.pushNotification;

  //initialize Pushwoosh with projectid: "GOOGLE_PROJECT_NUMBER", pw_appid : "PUSHWOOSH_APP_ID". This will trigger all pending push notifications on start.
  pushNot.onDeviceReady({ projectid: "xxxxxxxxx", pw_appid : "xxxxx-xxxxx" });

  //register for pushes
  pushNot.registerDevice(
      function(pushToken) {
        console.log('push token: ' + pushToken);
      },
      function(status) {
        console.log(JSON.stringify(['failed to register ', status]));
      }
  );

};

but there is no /registerDevice request in the xcode log. These are the logged requests: registerUser, applicationOpen, getInApps

3. Could you please specify the version of the plugin and the version of the Cordova itself?

Here is some information about my enviroment:

Cordova CLI: 6.0.0

com.pushwoosh.plugins.pushwoosh version: 4.2.0

OS: Mac OS X El Capitan

Xcode version: Xcode 7.2.1 Build version 7C1002

4. Have you tried our Sample App? Is the issue reproducible with it?

I will try it out and post to this thread when im finished.

5. By any chance, do you know whether it works for Android?

It works for Android.

permanent link
answered 14 Mar '16, 21:31
jQrgen's gravatar image

jQrgen
2614

Here are some warnings i get in xcode when i do cordova build ios.

alt text

permanent link
answered 14 Mar '16, 22:30
jQrgen's gravatar image

jQrgen
2614

The example didn't register the device on the pushwoosh application. I entered the correct application id

it also crashed once leaving this error (it didnt crash every time): 2016-03-16 21:11:44.337 pushwoosh-ionic-sample[1454:2212393] Received memory warning. Message from debugger: Terminated due to memory issue

This was all tested on a mac.

permanent link
answered 16 Mar '16, 21:09
jQrgen's gravatar image

jQrgen
2614

That is actually really weird that it didn't register the device on the Sample app.

I've passed your request to our developers, lets see what they'll find.

Please, stay tuned.

permanent link
answered 18 Mar '16, 05:45
Nikolai's gravatar image

Nikolai
3585

I am experiencing the same exact issue for a regular Cordova project.

The app appears to seize execution along with that error. If i remove the plugin, the app works just fine.

permanent link
answered 18 Mar '16, 09:51
Nicklas's gravatar image

Nicklas
112

By using version 4.2.1 im getting the same symptoms but the app does not seize execution.

(18 Mar '16, 10:10) Nicklas Nicklas's gravatar image

Could you please contact our support service at help@pushwoosh.com and attach the Sample project that crushes?

permanent link
answered 21 Mar '16, 08:19
Nikolai's gravatar image

Nikolai
3585

This solved it for me:

cordova platform rm ios cordova platform add ios@4.1.0

I had cordova-ios 4.0.1 previously, which i believe is the stabile version currently.

permanent link
answered 21 Mar '16, 11:44
Nicklas's gravatar image

Nicklas
112

I had cordova-ios 4.0.1, now i upgraded the project(Not sample project) to 4.1.0:

ionic platform now returns: "Installed platforms: ios 4.1.0"

Now i get the following error in xcode when building to my iphone: x | Pushwoosh request: | Url: https://cp.pushwoosh.com/json/1.3/getInApps | Payload: {"request":{"device_type":1,"language":"en-GB","application":"","userId":"1DD5F14A-AC72-4B49-B758-D76C65BFB4CE","v":"3.1.1.434","hwid":"1DD5F14A-AC72-4B49-B758-D76C65BFB4CE"}} | Status: "0 server error" | Response:

The screen is still white after build.

permanent link
answered 29 Mar '16, 18:22
jQrgen's gravatar image

jQrgen
2614

edited 29 Mar '16, 18:26

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×445
×352
×76
×39
×26

question asked: 06 Feb '16, 07:26

question was seen: 2,164 times

last updated: 17 Aug '16, 13:12