I am in the process of updating some deprecated code (Obj-C) in an application that was using the NSUserNotification classes to use the newer UserNotifications and UNUserNotificationCenter. I added code to prompt the user with the requestAuthorizationWithOptions function.
This function always returns a value of granted=false and the error is "Notifications are not allowed for this application". When I look at the system preferences, my Application is in the list, however, the Allow Notifications switch is disabled.
I did create a new project in Swift, and was able to get this working as expected.
Am I missing something in my original application that would cause the notifications not to work, and cause the requestAuthorizationWithOptions function to return the error?
Thanks,
Don
Post
Replies
Boosts
Views
Activity
I have a script that builds a macOS application, does the code signing and then does the zip and notarization.
For the notarization:
ZIPPATH="/Users/AProgrammer/dev/App.zip"
/usr/bin/ditto -c -k --keepParent "$APPPATH" "$ZIPPATH"
xcrun notarytool submit "$ZIPPATH" --keychain-profile 'appbuild-notary' --wait --timeout 5m
Conducting pre-submission checks for App.zip and initiating connection to the Apple notary service...
Submission ID received
id: 4dd17e33-5ea0-4e55-a859-a207ec88a4b1
Successfully uploaded file35.3 MB of 35.3 MB)
id: 4dd17e33-5ea0-4e55-a859-a207ec88a4b1
path: /Users/AProgrammer/dev/App.zip
Waiting for processing to complete. Wait timeout is set to 300.0 second(s).
Current status: Invalid...........
Processing complete
id: 4dd17e33-5ea0-4e55-a859-a207ec88a4b1
status: Invalid
This was working a few weeks ago, but now the notarization process shows as Invalid. I have run this many times, with the same result. The stapling step cannot complete as the notarization is not valid.
Is this an issue with the notarization server?
Thanks,
Don Metzler
I am looking at the requirements to develop a network extension.
Does a network extension have to be contained within an application? Or could it be contained within a plugin bundle and run from a daemon that loads this plugin?
Thanks,
Don