We are attempting to enable provisional notifications in our app, but some internal users on iOS 17 are reporting that they are not receiving the "Keep" and "Turn off" buttons that provisional notifications are supposed to have - in other words they just come in as regular quiet notifications.
I have confirmed that these users are doing a fresh install of our app, and at no point are they ever receiving a permission prompt to turn on notifications. Their UNAuthorizationStatus is correctly being set to provisional. Their notification settings are being set to the following, which seems correct:
I have not been able to reproduce this issue on any of my own devices, but these users can do so consistently. What could possibly cause this? Some misconfiguration on our end, our some hidden iOS setting somewhere?
Notification Center
RSS for tagCreate and manage app extensions that implement Today widgets using Notification Center.
Posts under Notification Center tag
49 Posts
Sort by:
Post
Replies
Boosts
Views
Activity
I schedule a local notification to remind me to check in at work at 8 am if I am not already checked in, the code is working fine when app is in foreground, but when I kill the app, it alway show alert no matter if I already checked in or not.
func userNotificationCenter(_ center: UNUserNotificationCenter, willPresent notification: UNNotification, withCompletionHandler completionHandler: @escaping (UNNotificationPresentationOptions) -> Void) {
let isCheckedIn = AppManager.shared.isCheckedIn()
if isCheckedIn {
completionHandler([])
} else {
completionHandler([.list, .sound, .banner])
}
}
I have a bundled application that contains a widget extension. On launching the application once the widget appears in the widget gallery, However, I have observed that If my widget extension is not sandboxed, the widget fails to show in the widget gallery. Is this expected? I am using the same xcode project and just that AppSandbox capability for the widget extension target is causing this. Can someone please explain why is this happening?
How can we identify whether the remote change notification is triggered because some data was changed on a different device and it is downloaded from CloudKit, or it is triggered from the current device because new entity was saved into database.
Because this notification is posted when both remote data is downloaded or local data is created. It would be great if there is a way to understand the origin of the notification.
Dear Apple support,
We are working on one of the projects related to BLE, in which our BLE device is acting as a GATT client and our iPhone device (iPhone 13, OS17.3) is acting as a GATT server.
Issue being faced: Whenever my BLE device subscribes to the ANCS notifications, and the moment the IOS device starts bombarding with the notifications available in notification center, the BLE device controller's heap memory becomes UNAVAILABLE in runtime for this notifications' queue and eventually making the BLE controller to reset. Thereafter, whenever user tries making a new connection session of BLE, again same thing repeats.
Notifications allowed in BLE display : W-SMS, W-CALL, SMS, CALL, none other than this.
Issue observed with : IF and ONLY 150 notifications and above available in notification center, otherwise our product works fine with iPhone with less number of notifications.
We would like to know how we can curb the number of PRE-EXISTING type notifications available in the notification center flowing towards the BLE device? What best solution can be done at the IOS side, we also have IOS APP team for this project. What kind of APIs does Core Bluetooth framework can provide to the IOS developer in order to overcome this issue.
Please suggest possible ways from the IPHONE device only to overcome this. BLE's software CANNOT BE CHANGED under any circumstances as the product is already in production and complaints are coming from end user (from the field).
OUR GOAL : ONLY notifications which will be available in run time, i.e. AFTER SUCCESSFUL BLE connection established to be displayed in the BLE's display. We DON'T WANT older notifications to be displayed and flow towards BLE over ANCS. WE MUST make 'notification popup' option as ALLOW to be shared with our BLE device, otherwise SMS,CALL, W-SMS,W-CALL during live connection will not come on the BLE 's display.
The Notification provides the uuid corresponding to the Item saved in SwiftData.
Goal is to open the correct DetailItem View when I tap the notification.
How can I achieve this?
@Model
final class Item {
@Attribute(.unique) var uuid: UUID
...
}
--
extension LocalNotificationManager: UNUserNotificationCenterDelegate {
func userNotificationCenter(_ center: UNUserNotificationCenter, didReceive response: UNNotificationResponse) async {
guard let userInfo = response.notification.request.content.userInfo["uuid"] as? Data else {
print("No data found in notification userInfo")
return
}
}
--
struct ItemList: View {
@Query var items: [Item]
@State private var path = NavigationPath()
var body: some View {
NavigationStack(path: $path) {
ForEach(Array(items.enumerated()), id: \.element.id) { index, item in
NavigationLink(value: item) {
ItemButton(item: item, index: index)
}
}
}
}.navigationDestination(for: Item.self) { item in
DetailItem(item: item)
}
}
Both the extension and the receiving application are in the same app group.
I can't find the issue. It doesn't seem to be a problem with entitlements. Maybe an issue with the string formatting/conversion? Maybe I am not allowed to send distributed center notifications from the camera extension?
I am sending the notification calling:
func notifyChangeInUsage() {
os_log("Notifying the virtual camera change in usage", log: cdsLog, type: .info) // this is logged
DistributedNotificationCenter.default().postNotificationName(NSNotification.Name("VirtualCamUsageChanged"), object: nil, userInfo: nil, deliverImmediately: true)
}
And receiving it in the other end, subscribing with
std::string notification = "VirtualCamUsageChanged"
[mObserverClassInstance subscribe:@(notification.c_str())];
where subscribe is the following method, which is tested to be working.
- (void)subscribe:(NSString *)notification {
[[NSDistributedNotificationCenter defaultCenter]
addObserver:self
selector:@selector(callCallback:)
name:notification
object:nil
suspensionBehavior:NSNotificationSuspensionBehaviorDeliverImmediately];
}
Dear Apple support,
We are working on one of the projects related to BLE, in which our BLE device is acting as a GATT client and my iPhone device (iPhone 13, 17.3) is acting as a GATT server.
Issue being faced: Whenever my BLE device subscribes to the ANCS notifications, and the moment the IOS device starts bombarding with the notifications available in notification center, the BLE device controller's heap memory becomes UNAVAILABLE in runtime for this notifications' queue and eventually making the BLE controller to reset. Thereafter, whenever user tries making a new connection session of BLE, again same thing repeats.
Notifications allowed : W-SMS, W-CALL, SMS, CALL, none other than this.
Issue observed with : 150 notifications and above available in notification center, otherwise our product works fine with iPhone.
We would like to know how we can curb the number of PRE-EXISTING type notifications available in the notification center flowing towards the BLE device?
What best solution can be done at the IOS side, we also have IOS APP team for this project.
What kind of APIs does Core Bluetooth framework can provide to the IOS developer in order to overcome this issue.
Please suggest possible ways from the IPHONE device only to overcome this. BLE's software CANNOT BE CHANGED under any circumstances as the product is already in production and complaints are coming from end user (from the field).
OUR GOAL : ONLY notifications which will be available in run time, i.e. AFTER SUCCESSFUL BLE connection established to be displayed in the BLE's display. We DON'T WANT older notifications to be displayed and flow towards BLE over ANCS.
WE MUST make 'notification popup' option as ALLOW to be shared with our BLE device, otherwise SMS,CALL, W-SMS,W-CALL during live connection will not come on the BLE 's display.
Hi there,
This is my first time posting here. I'm working on small projects on Swift and SwiftUI now and then. I'm currently trying to develop an application that gets some bus arrival data using API and displaying them with live activities. The thing is that I'm not quite sure how frequently updates work yet. Still trying to figure out if I can update the live activity everytime the data coming right from the API changes or use push notification updates each minute passing by, but that is another thread that I'm going to focus with more details.
Everytime i'm trying to deploy my app on my iphone or a simulator this error keeps popping up and I can't figure out why.
Any ideas? Let me know if you need any snippet of my code.
SendProcessControlEvent:toPid: encountered an error: Error Domain=com.apple.dt.deviceprocesscontrolservice Code=8 "Failed to show Widget 'com.gregorikouk.MapKitTut.BusWidgetKit' error: Error Domain=FBSOpenApplicationServiceErrorDomain Code=1 "The request to open "com.apple.springboard" failed." UserInfo={NSLocalizedFailureReason=The request was denied by service delegate (SBMainWorkspace)., BSErrorCodeDescription=RequestDenied, NSUnderlyingError=0xb1282dfe0 {Error Domain=SBAvocadoDebuggingControllerErrorDomain Code=1 "Failed to get descriptors for extensionBundleID (com.gregorikouk.MapKitTut.BusWidgetKit)" UserInfo={NSLocalizedDescription=Failed to get descriptors for extensionBundleID (com.gregorikouk.MapKitTut.BusWidgetKit)}}, FBSOpenApplicationRequestID=0xe5da, NSLocalizedDescription=The request to open "com.apple.springboard" failed.}." UserInfo={NSLocalizedDescription=Failed to show Widget 'com.gregorikouk.MapKitTut.BusWidgetKit' error: Error Domain=FBSOpenApplicationServiceErrorDomain Code=1 "The request to open "com.apple.springboard" failed." UserInfo={NSLocalizedFailureReason=The request was denied by service delegate (SBMainWorkspace)., BSErrorCodeDescription=RequestDenied, NSUnderlyingError=0xb1282dfe0 {Error Domain=SBAvocadoDebuggingControllerErrorDomain Code=1 "Failed to get descriptors for extensionBundleID (com.gregorikouk.MapKitTut.BusWidgetKit)" UserInfo={NSLocalizedDescription=Failed to get descriptors for extensionBundleID (com.gregorikouk.MapKitTut.BusWidgetKit)}}, FBSOpenApplicationRequestID=0xe5da, NSLocalizedDescription=The request to open "com.apple.springboard" failed.}., NSUnderlyingError=0xb1281d830 {Error Domain=FBSOpenApplicationServiceErrorDomain Code=1 "The request to open "com.apple.springboard" failed." UserInfo={NSLocalizedFailureReason=The request was denied by service delegate (SBMainWorkspace)., BSErrorCodeDescription=RequestDenied, NSUnderlyingError=0xb1282dfe0 {Error Domain=SBAvocadoDebuggingControllerErrorDomain Code=1 "Failed to get descriptors for extensionBundleID (com.gregorikouk.MapKitTut.BusWidgetKit)" UserInfo={NSLocalizedDescription=Failed to get descriptors for extensionBundleID (com.gregorikouk.MapKitTut.BusWidgetKit)}}, FBSOpenApplicationRequestID=0xe5da, NSLocalizedDescription=The request to open "com.apple.springboard" failed.}}}
Domain: DTXMessage
Code: 1
User Info: {
DVTErrorCreationDateKey = "2023-10-02 21:06:04 +0000";
}
--
System Information
macOS Version 14.0 (Build 23A344)
Xcode 15.0 (22265) (Build 15A240d)
Timestamp: 2023-10-03T00:06:04+03:00