Push not working in my app

W released a Push Enabled app recently. Although several users have purchased the app, we are seeing NO TOKENs being sent to our servers. We are unclear on what is going on?
1. We built the app on the 3.0 SDK application for Device 2.0, but as we are supporting Push Notification, we have Push related API's inside #ifdef _IPHONE_30 macros. Will 3.0 API's inside #ifdef _IPHONE_30 macro be compiled and when installed on a 3.0 Device will these API's get executed? That was our expectation but again we are not seeing any tokens coming through.
2. We see apps out there similar to ours that support 2.0 and 3.0 in the same build, and have Push features on 3.0. We assume the way to do that is to build with #def macros as described in #1 above, and that is what we did. Is that wrong? Must an app supporting Push be exclusively built for 3.0 Device and can not support 2.0 devices?
Thanks in advance
Jay

Hi Jay - It might make more sense to review some basics instead of attempting direct answers to each of your questions.
Firstly, you can't use a compiler switch to determine which code blocks are selected at runtime. If a block of 3.0 code is switched in at compile time (i.e. added to the app), that block will be executed by all of the host devices. If the code isn't supported by lower iPhone OS versions, the app would crash on those systems (if allowed to load). On the other hand, if the 3.0 code is switched out at compile time, it's not added to the app and won't be executed by any of the host devices.
You may have been thinking of a runtime switch which detects the OS version and bypasses any incompatible code. There are ways of doing that on some platforms, but AFAIK such a build wouldn't work for an approved iPhone app because the app needs to be branded based on the lowest OS it supports. I.e., if I include 3.0-only features, the app will be marked 3.0 and OS 2.x will refuse to run it.
Although several users have purchased the app, we are seeing NO TOKENs being sent to our servers. We are unclear on what is going on?
It would appear that your #ifdef has switched out the code in question. If you're not sure whether a block of code is included in your app, I would recommend NSLog(). E.g.
#ifdef _IPHONE_30
NSLog(@"IPHONE30");
#endif
The above tells you if a compile time switch is turned on for the current build. I generally like to know what code was included in my app before it's out in the field.
We see apps out there similar to ours that support 2.0 and 3.0 in the same build, and have Push features on 3.0.
AFAIK, any build that has 3.0 features can't support 2.0, and any build that supports 2.0 can't include code that only runs on 3.0.
Each Xcode build is subject to two OS version settings:
1) The SDK version;
2) The Executable version.
Here's an article that explains these settings: [http://resources.pinchmedia.com/docs/pinchanalytics/iPhone_SDK_30_2xTargets].
For example, if you build for 2.1 using the 3.0 SDK, the compiler won't recognize API calls that are only available in 2.2 or 3.0, and the build will be marked 2.1 so any iPhone OS below 2.1 won't run it.
Hope that helps!
- Ray

Similar Messages

  • Yhoo mail Push Not Working?

    He,
    iPhone 3GS OS 3.1, Yhoo mail Push Not Working?
    thanks

    I have also been having the Y!Mail push issue. I noticed it several weeks ago. It used to be that I would get the email push almost immediately after Y!Messenger told me that I received an email. I now will receive the email push sometimes 30 minutes later, sometimes 40 minutes, sometimes hours later. And sometimes never, because I opened up the Mail widget and it does the fetch. Here is what I have done so far (I do hard restarts each time I make a change): I deleted my Y mail account on the iPhone and added it back. No workee for me. I turned wi-fi off so that I am on 3G. Nope - no pushes. I turned on all of my secondary mail servers. Still no workee. I removed all my installed apps, thinking one of them might be causing interference, but no difference. I have performed Restores on the iPhone with no change. I contacted Y!Mail Tech Supt. We swapped emails a couple of times; still don't get the email pushes. Last email from them requested that I send some information to an AT&T employee who would be working on this issue. Well, I sent the info but haven't heard back from him. Very frustrating.
    So just to see if it was my iPhone or a system problem, I sent a test email to my wife's iPhone 3Gs. I sat with the phone for over an hour and no email push. I asked my brother(iPhone 3G) if he gets his email pushes. He says he has never received an email push from Y!Mail since he got the phone last spring.
    So is this an Apple issue? Or Yahoo? Or AT&T? Should I make an appt at the Apple Genius Bar and see if one of their gurus can fix it? Maybe one of the Apple iPhone techs that monitor this forum can chime in.

  • My "update all" buton will not work in the app store.  It gives me a message saying there is not enough storage to update.. I know i have storage left on the phone.  I even bought more icloud storage.  Any ideas??? Please help??? thanks

    My update all button will not work in the app store.  It keeps giving me a crazy message about not having enough storage to update apps.  Please help? I know i have storgage on icloud and on the phone itself.  Any ideas? Thanks

    Try deleting the old backup.
    Settings>iCloud>Storage & Backup>Manage Storage, tap the device name and on the resulting screen, scroll down and tap on Delete Backup.

  • Mail is not working. The app opens because I see a light on under "Mail" in the dock.

    Mail is not working. The app opens because I see a light on under "Mail" in the dock, and I see the menu at the top of my screen, but I don't see the app itself or any windows. It is like it is running in the background, but I can't see it. Everthing is subdued when I click on the choices up in the menu. I have tried "Force Quit" and then re-opening the mail app several times, and have rebooted my notebook twice. What is weird is that this started right after I changed my password in a browser (it is a gmail account). I went into the System Preferences on my MacBook and changed my password there as well, so it should be setup properly to open. I am running Mac OS X Lion 10.7.5.   Any help anyone can provide is much appreciated.

    The current Mail version for 10.6.8 Snow Leopard is 4.6 (1085).   Run Software update or the combo updater ... Mac OS X 10.6.8 Update Combo v1.1

  • HT1368 My wishlist is not working on the app store i can not find the add to wishlish icon but it is working fine with the itunes store so i am able to add films and music but not apps does anyone know how to fix this

    My wishlist is not working in the app store on my ipad it is woking fine in itunes store so i can add films and music but the icon "add to wish list" is not available on the app store so does anyone know how to fix this 

    The wish list only works on apps you have to pay for. To get it tap the icon of the app you want to save. After it opens at the upper right corner is a box with a arrow. Tap that then tap add to wish list list in the box that opens.

  • Hello, my iphone 5s fell, thereafter i tried taking a picture, the camera app just shows a black screen and hangs, the front camera works on other apps but the rear camera is not working, all other apps work perfectly well, how do i resolve this

    Hello, my iphone 5s fell, thereafter i tried taking a picture, the camera app just shows a black screen and hangs, the front camera works on other apps (such as facetime and skype) but the rear camera is not working, all other apps work perfectly well, how do i resolve this

    Double tap Home button and delete Camera app from multitask-list.
    Do a
    Reset: Hold down the Sleep/Wake button and the Home button at the same time for at least ten seconds, until the Apple logo appears. Note: You will not lose any data
    If problem persist, make an appointment with genius bar for evaluation.

  • Add to Address Book not working in mail.app

    On all my computers : MacBook Air and Mac Mini, the Add to Address Book (command + Shift + Y) is not working in Mail.app.
    It doesn't add the email and name in the Address Book (now called Contact).
    Is this a broken link ?
    Best. StG

    Hey Saint-Georges -
    I've got the same issue in the console.  I didn't notice the keyboard shortcut not working but that's happening to me as well.  
    I've gone gone through and repaired the disk and disk permissions.  Still no luck.
    Hopefully someone has a fix.
    Rob
    From the Console:
    6/3/13 5:27:53.922 PM assistantd[4667]: <Error>: Daemon - Sync chunk denied! Canceling sync. [SASyncChunkDenied
      aceId: "26234165-b039-4219-af4d-8f4fa5561ebd"
      properties:
        callbacks: <empty array>
        errorCode: 0
      group: "com.apple.ace.sync"
      refId: "3274A842-6638-4E54-AFB3-F669BCCED462"
      v: "1.2"
      class: "ChunkDenied"]

  • [svn] 3913: BLZ-272 Two long polling endpoints not working in same app with Firefox

    Revision: 3913
    Author: [email protected]
    Date: 2008-10-27 13:49:02 -0700 (Mon, 27 Oct 2008)
    Log Message:
    BLZ-272 Two long polling endpoints not working in same app with Firefox
    The long polling waitMonitor object in the FlexSession did not keep track of
    blocking polls via endpoint ID. This prevented the second channel from blocking.
    Enhance the FlexSession.waitMonitor to be a map of endpointID to
    EndpointQueue objects, and keep track of the monitors based on what endpoint
    they are associated with.
    QA: Yes
    Doc:No
    Checkintests: passed
    Ticket Links:
    http://bugs.adobe.com/jira/browse/BLZ-272
    Modified Paths:
    blazeds/branches/3.0.x/modules/core/src/java/flex/messaging/FlexSession.java
    blazeds/branches/3.0.x/modules/core/src/java/flex/messaging/client/FlexClient.java

    Revision: 3913
    Author: [email protected]
    Date: 2008-10-27 13:49:02 -0700 (Mon, 27 Oct 2008)
    Log Message:
    BLZ-272 Two long polling endpoints not working in same app with Firefox
    The long polling waitMonitor object in the FlexSession did not keep track of
    blocking polls via endpoint ID. This prevented the second channel from blocking.
    Enhance the FlexSession.waitMonitor to be a map of endpointID to
    EndpointQueue objects, and keep track of the monitors based on what endpoint
    they are associated with.
    QA: Yes
    Doc:No
    Checkintests: passed
    Ticket Links:
    http://bugs.adobe.com/jira/browse/BLZ-272
    Modified Paths:
    blazeds/branches/3.0.x/modules/core/src/java/flex/messaging/FlexSession.java
    blazeds/branches/3.0.x/modules/core/src/java/flex/messaging/client/FlexClient.java

  • Updates tab not working in the App Store

    The updates tab is not working in the App Store. I have to go to purchased tab to find the apps that need updating. How can I fix this? I've turn off the iPad multiple times hoping it will reboot but it doesn't help.

    Apparently there are problems updating updates on iOS devices >  Apps update not working. Was before but...: Apple Support Communities
    Try again later or tomorrow.
    It's been reported to Apple.

  • Geolocation on Geeksphone not working at neither app

    I wrote an app, that worked fine in simulator. Get the self position with geolocation and put markers on map. But on Geeksphone geolocation not working on this app, Here maps or if i just simple go to google maps.

    Your best bet is to ask on the #gaia or #b2g channels on IRC.
    *see: https://wiki.mozilla.org/Irc

  • HT4623 my apple i pad is currently not working and no apps are opening  pls clarify it

    my apple i pad is currently not working and no apps are opening  pls clarify it

    Are there any error messages?
    Knowing what you see or are experiencing can help diagnose it.
    In the meantime, a common fix, hold down the sleep and home keys for about 20 seconds and see if you can force it to rebood. If you see a silver apple, let go and let it reboot and see if that helps.

  • Apple id not work for mac app store, what happen? It is available for others such as iTunes, my iPhone and iPad

    apple id not work for mac app store, what happen? It is available for others such as iTunes, my iPhone and iPad

    Try deleting the cache associated with the App Store..
    Quit the App Store if it's open.
    Open the Finder. From the Finder menu bar click Go > Go to Folder
    Type this exactly as you see it here:
    ~/Library/Caches/com.apple.appstore/Cache.db
    Click Go
    Move the Cache.db file to the Trash.
    Relaunch the App Store. See if that made a difference.

  • 1st think my billing info is not support debit card not support by apple 2nd think is my old I'd is not working even free app in app store......

    1st think my billing info is not support debit card not support by apple 2nd think is my old I'd is not working even free app in app store......

    1st think my billing info is not support debit card not support by apple 2nd think is my old I'd is not working even free app in app store......

  • Iphone 4 push notifications not working for any app

    hi, Actually I own an iPhone 4 os 4.2.1(8c148). The thing is that push notification for all the apps that support this feature is not working, I've been an iphone user for long time now, so I konw all the stuff about turning on the push notifications etc. the problem is that my phone give me the pushes like 1 hr or 2 late, or some times never , i just have to open the apps to see my new messages and stuff. Since i live in colombia I have brought the iphone to the store and they take it for like a week and then they give me the phone back saying that is ok , but it isn't. I' have reinstalled the software, I've done anything you can think of, like turning on an of push notification, put it in plane mode, restore as new, backups, and I don't know what else to do, and the thing is that in colombia they don't exchange your phone that easy as it is in the US. So please any advise? ANd I'm sorry about my English. Thank you!

    Unfortunately you have already done everything we can possibly instruct you to do.. at this point the only option is getting them to exchange it its under warranty its not working you have to get a exchange

  • Push Notifications not working on any app (Whatsapp, Beejive, Mail) after update 5.1.1, Help!

    I'm gonna try to be clear with my problem. I have a Gmail Account working on Microsoft Exchange, for IM messaging I'm using Beejive IM with Push and I'm also using Whatsapp.  Before Updating it to iOS 5.1.1 all Push notifications were working flawless, however, after I upgraded it to 5.1.1, I began having troubles. After 1 minute of having the Iphone locked, I don't get any push notification, nor on the email, nor on the Whatsapp, neither on the Beejive. If I unlock it and I re-open one of them, for ex, I go to check my contact list on Beejive, I get all the mails, and all the instant msgs that people had sent to me after I locked my iPhone; it's like, my iPhone was locked for 30 minutes. In those 30 minutes people sent me 4 msgs on whatsapp, 4 msgs on beejive and 4 mails. Once I unlock my iPhone and I go to one of the 3 apps (mail, whatsapp or beejive), I get the 12 items (4 msg from whatsapp, 4 msgs from beejive and 4 mails) at that exactly time. It's crazy, it's like, with this new update push notifications got disabled for every app or what happened to my iPhone on this upgrade? I really need help. WIthout Push, none of them apps works cool for me. I'm using Iphone 4 on a 3G network.
    Ps: I tried restoring it x3, I unistalled the apps, mail, etc and nothing worked.
    PS2: If someone is using whatsapp or beejive im with push on the new iOS 5.1.1 and push notifications are working good for them, please let me know it so I will know it's my iPhone hardware problem to bring it to technical service
    Thanks in advance

    SAME PROBLEM
    The Apple store are trying to say they know nothing of this problem,  they know that if  you delete your yahoo mail and then add the account again then push notification works for a day.  So they do that for you, but won't listen when you tell them that it won't be working by the next day! This is to get you out of the shop.  They don't have an answer to why your other notifications aren't working (like alerts etc) even though you have push on.
    So what are we to do?  The main point for me getting an iPhone was being able to be alerted when I received an email as I am out and about all day!
    How can we get somebody in Apple to admit this problem and find a resolve for it before we all have to go buy a phone that will notify you of your email, messages ans alert?

Maybe you are looking for

  • Need some help in the login form ???!?!?!?!!

    can any one help me with correcting the code or can any one give me another code for using it in the login form. this is my problem:- i had make a login form using in oracle 9i form builder >>>in this form i have three text boxes one for intering use

  • AMT Subsystem Error in Dreamweaver CS4

    I get this error after installing CS4 Web Premium yesterday - it worked then but not now.   All other CS4 Web elements say "Licensing for this product has stopped working"  and I get an Error 147:20 code Anyone encountered this, or know a solution? T

  • How to kill TP process at OS Level

    Dear ALL, How to kill the TP process at OS level Operating System : win 2003

  • How to read USER1 DIP-switch status of a cRIO chassis from FPGA?

    How can I  read the status of the DIP switches on a cRio chassis from the FPGA? I am working with a  cRIO 9022.. My idea is to set the system into a "service" mode by setting the USER1 switch to ON and communicate with the FPGA via the FPGA-GUI(VI) o

  • Binding definition error with programmed binding classes

    Hi all, 640/NW04s/ECC5 SP14 system, I'm trying to use a programmed container->container binding class. I've created my class implementing interface IF_SWF_IFS_BIND_TRANSFORM_CONT, but when I try to put it into the binding editor, it complains with: S