Post

Replies

Boosts

Views

Activity

NSWorkspace.shared.openApplication Permission Issue
Hello, I replaced the following line of code: NSWorkspace.shared.launchApplication(newPath) With this: let url = URL(fileURLWithPath: newPath) let configuration = NSWorkspace.OpenConfiguration() configuration.arguments = [newPath] NSWorkspace.shared.openApplication(at: url, configuration: configuration, completionHandler: nil) ...because 'launchApplication' is deprecated in macOS 11.0. The code compiles without issue, however on login I receive an error stating that "[APP_HELPER] does not have permission to launch [APP]". I had no such issue when using 'launchApplication', and this only occurred when changing it to 'openApplication'. I'm sure I'm missing something obvious here with regards to sandboxing and permissions for my helper app to launch my app, but I'm lost. Any ideas?
2
1
1.2k
Apr ’22