I have the following situation:
My SwiftUI App for macOS is using App Sandbox and is currently configured for read/write access for all the locations selectable in XCode
I have added a file selector using a button and NSOpenPanel() to let the user select a folder containing a database file, to which I successfully get permissions using URL.bookmarkData() and URL.startAccessingSecurityScopedResource()
I then try to read file paths from the database file and open those but I instantly get a permission error without a permission dialog/prompt appearing
In my test I am using paths to files in my iCloud Drive folder
I added all file/folder related usage string entries to the Info.plist for testing
I think this is weird, since I can paste one of those file:// URLs from the database into a (non-Safari) browser and it shows the native permission dialog/prompt before downloading the file as expected.
Is there any usage string that's not shown in the Info.plist Dropdown in XCode that I need to add to my app in order for this to work?