-
Notifications
You must be signed in to change notification settings - Fork 198
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OneSignal not working after Xcode 10.0 update #428
Comments
After some investigation, it looks like apps built very specifically with Cordova in Xcode 10 seem to be missing the embedded mobile provisioning file. Our SDK needs to know if your app is a development or production version so it knows what APNS certificate to use. It accomplishes this by reading a file called This works just fine in iOS 12 + Xcode 10......except with Cordova. Specifically, the following line returns nil when it should be returning a provisioning file. [[NSBundle mainBundle] pathForResource:@"embedded" ofType:@"mobileprovision"] We are continuing to investigate and may end up filing a bug with Cordova over this - I understand this can be a time critical issue and I apologize that you are seeing it. |
Same problem here :( Thanks! |
I have the exactly the same problem with iOS 12 |
I can confirm that this is an issue with the Cordova SDK and Xcode 10. Fortunately there does seem to be a workaround: apache/cordova-ios#407 Essentially Cordova is not bundling the I will be keeping this issue open so that people don't create duplicates |
@Nightsd01 this workaround works for me. Did I understand correctly that I can't deploy the app to apple app store with this workaround? |
In xCode if you go to File -> Workspace Settings you can change the Build System to Legacy Build System and your Push notifications will be received in iOS device. |
@Sveen without the workaround, Cordova projects in Xcode 10 will produce apps that don’t include an |
@Nightsd01 Yes, I understand. But my question was, when I use the workaround (which works good), I can publish the app to the App Store or will Apple reject the app? |
@sveeen Unless there are other issues with Cordova in Xcode 10 that I am unaware of (and there may very well be), you should be good to go. In the worst case, with the error we're discussing above, you wouldn't have even been allowed to upload the app, it would not have reached the review process. |
An alternative would be to temporarily go back to Xcode 9.x You can download it at: |
@spinninghamster but only when your iOS device is on ios11. When you are on ios12 Xcode 12 is mandatory. |
In previous versions the push also does not work |
What permissions does OneSignal need? |
Just as a note to folks who start reading this thread, the workaround for this issue is here: I also want to make it very clear that this is not an issue with our SDK. It is an issue with how Cordova embeds mobile provisioning files in apps in Xcode 10. We cannot fix this issue - only Cordova can. But in the mean time, the workaround above should fix the problem as a temporary solution. |
@joaoduartemariucio If you are not able to get push working in previous versions of Xcode you are facing a different issue and should contact the support through our website dashboard |
@Nightsd01 Hello, I'm using Xcode 10. I've seen the mentioned question, it's not clear to me what I should do to get the push to work again using Xcode 10. I understood that there is a new way of building the project in this new version, but I could not identify what should be done. Can you help me? |
Have anyone succesfully published your apps to the appstore with that workaround? Cause now i get an Invalid Signature error from Apple Connect. |
@LaloCastilla I used Xcode 9.4 to publish my application because in Xcode 10 regardless of the device I was running it did not get push |
@LaloCastilla |
@sveeen What alternative solution? |
@joaoduartemariucio Take a look here: |
thank you |
It works !!!! Thank you very much. I received no notifications since ios 12. |
I am bit confused, we do know that to make your build end correctly on Xcode 10.1 for IOS12.1 you need a workaround (command line or Xcode Menu)... that's ok ..and the buiLd, run on device, and notifications...All good.. but the checking on upload to apple store for review will fail ..>>> "The asset catalog at Assets.car' can't be processed. Rebuild your app, and all included So, back and try doing it on new build....the build, run on device all good...but notifications are not working, you see the device on OneSignal dashboard, the device can send and trigger notifications to other playerIds, but did receive nothing. |
To prevent Mismatched User errors, upgrade cordova-ios to 5.0.0 (issue should be fixed) |
Update from @jkasten2: This issue is a compatibly issue with Cordova and Xcode 10.
See this issue for a work around: apache/cordova-ios#407
Description:
We have updated to the last version of Xcode 10.0 and integrated the last version of the onesignal Cordova SDK to our company application. The App builds without problem. When the app starts we can see our device added to the onesignal dashboard but when we try to send a notification it fails.
At the dashboard we have received a warning that says the following:
"Apple returned a BadDeviceToken error. Some users are tied to a different environment from your sending environment.
This warning occurred 10 times, last occurring half a minute ago.
Affected users: 97f0aa1f-9920-4edc-97fa-fd8170965e2c, 03fdf464-5d86-49ac-b57b-5c93e25448fd, and 94efb08f-9778-4ed9-8ba6-0faffd97b335"
We are using the same push certificate of the app that it is currently in the app store.
We have followed the instructions to integrate the IOS SDK BETA via cocoapods to our ios ionic build, but the same error occurs.
Also we are using the same bundle id.
We were about to make an important update to our app so we need your help.
The text was updated successfully, but these errors were encountered: